Install
openclaw skills install china-cloud-deployDeploy applications to Chinese cloud platforms (Tencent Cloud, Alibaba Cloud, Huawei Cloud) using their official CLIs. Teach AI agents how to deploy to SCF (Serverless), Lighthouse (VPS), OSS/COS (object storage), and Container Registry on China's three major cloud providers. Covers: Tencent Cloud SCF function deployment, Alibaba Cloud FC + OSS static hosting, Huawei Cloud FunctionGraph, cross-cloud deployment strategy, and ICP filing guidance. Triggers on: 中国云部署, china cloud deploy, 腾讯云部署, tencent cloud deploy, 阿里云部署, alibaba cloud deploy, 华为云部署, huawei cloud deploy, SCF部署, serverless china, 国内云服务部署, china serverless, ICP备案, icp filing, 国内VPS部署, china VPS deploy, COS上传, OSS上传, 中国云CLI, china cloud CLI
openclaw skills install china-cloud-deployYou are an expert at deploying applications to China's three major cloud platforms using their official CLI tools. You handle the unique challenges of deploying in China: ICP filing, Great Firewall considerations, and platform-specific quirks.
Deploying in China is not just deploy — it's ICP + deploy + CDN + monitor. Each step has regulatory requirements that don't exist elsewhere. You guide agents through the full pipeline.
| Platform | CLI | Install | Best For |
|---|---|---|---|
| Tencent Cloud | tccli | pip install tccli | SCF serverless, Lighthouse VPS, COS storage |
| Alibaba Cloud | aliyun | pip install aliyun-python-cli | FC serverless, OSS storage, ECS VPS |
| Huawei Cloud | hcloud | pip install hcloud | FunctionGraph, OBS storage, ECS VPS |
When: Deploy API/function as serverless on Tencent Cloud
# Install CLI
pip install tccli
# Configure credentials
tccli configure
# SecretId: AKIDxxxxx
# SecretKey: xxxxxxx
# Region: ap-shanghai
# Verify
tccli scf ListFunctions --limit 1
# Step 1: Package function code
cd /path/to/function
zip -r function.zip index.js node_modules/ # Node.js
# or
zip -r function.zip main.py requirements.txt # Python
# Step 2: Create or update function
tccli scf CreateFunction \
--FunctionName "my-api" \
--Runtime "Nodejs18.15" \
--Handler "index.main" \
--Code '{"ZipFile": "'$(base64 -w0 function.zip)'"}' \
--Timeout 30 \
--MemorySize 256
# Step 3: Create HTTP trigger (Function URL)
tccli scf CreateTrigger \
--FunctionName "my-api" \
--TriggerName "http-trigger" \
--Type "http" \
--TriggerDesc '{"AuthType":"NONE","NetConfig":{"EnableIntranet":false,"EnableExtranet":true}}'
# Step 4: Get function URL
tccli scf ListTriggers --FunctionName "my-api"
# Update code only
tccli scf UpdateFunctionCode \
--FunctionName "my-api" \
--ZipFile "$(base64 -w0 function.zip)"
# Update configuration
tccli scf UpdateFunctionConfiguration \
--FunctionName "my-api" \
--Timeout 60 \
--MemorySize 512 \
--Environment '{"Variables":[{"Key":"NODE_ENV","Value":"production"}]}'
# Create layer for large dependencies
mkdir -p layer/nodejs && cd layer/nodejs
npm install express cors dotenv
cd ../.. && zip -r layer.zip layer/
tccli scf PublishLayerVersion \
--LayerName "nodejs-deps" \
--CompatibleRuntimes '["Nodejs18.15"]' \
--Content '{"ZipFile": "'$(base64 -w0 layer.zip)'"}'
# Attach layer to function
tccli scf UpdateFunctionConfiguration \
--FunctionName "my-api" \
--Layers '[{"LayerName":"nodejs-deps","LayerVersion":1}]'
When: Deploy static site or SPA on Alibaba Cloud
pip install aliyun-python-cli
aliyun configure
# AccessKey ID: LTAIxxxxx
# AccessKey Secret: xxxxxxx
# Region: cn-shanghai
# Step 1: Create OSS bucket
aliyun oss mb oss://my-static-site --region cn-shanghai
# Step 2: Set bucket to static website mode
aliyun oss website oss://my-static-site \
--index-document index.html \
--error-document 404.html
# Step 3: Upload built files
aliyun oss cp ./dist/ oss://my-static-site/ --recursive
# Step 4: Set public read
aliyun oss acl oss://my-static-site --acl public-read
# Step 5: Bind custom domain (requires ICP)
aliyun oss bucket-cname oss://my-static-site --domain www.example.com
# Step 1: Deploy function using fun (FC CLI)
npm install -g fun
# Step 2: Create template.yml
cat > template.yml << 'EOF'
ROSTemplateFormatVersion: '2015-09-01'
Transform: 'Aliyun::Serverless-2018-04-03'
Resources:
my-api:
Type: 'Aliyun::Serverless::Service'
handler:
Type: 'Aliyun::Serverless::Function'
Properties:
Handler: index.main
Runtime: nodejs18
CodeUri: ./
Timeout: 30
MemorySize: 256
Events:
httpTrigger:
Type: HTTP
Properties:
AuthType: ANONYMOUS
Methods: ['GET', 'POST']
EOF
# Step 3: Deploy
fun deploy
When: Deploy on Huawei Cloud
# Install CLI
pip install hcloud
# Configure
hcloud configure
# AK: xxxxx
# SK: xxxxx
# Region: cn-north-4
# Deploy function
hcloud FunctionGraph CreateFunction \
--function_name "my-api" \
--runtime "Node.js18.17" \
--handler "index.main" \
--code_type "zip" \
--func_code "$(base64 -w0 function.zip)"
When: Need redundancy or multi-cloud architecture
Use Case → Recommended Platform
─────────────────────────────────────────────────────
Serverless API → Tencent SCF (best CLI) or Alibaba FC
Static Site → Alibaba OSS (cheapest CDN)
VPS / Long-running service → Tencent Lighthouse (best value)
Container → Alibaba ACR + ECS
Database-heavy → Alibaba (best RDS options)
Government/State client → Huawei Cloud (compliance)
#!/bin/bash
# deploy-multi-cloud.sh
APP_NAME=$1
ENV=$2 # staging | prod
case $ENV in
staging)
# Deploy to Tencent SCF for testing
tccli scf UpdateFunctionCode \
--FunctionName "${APP_NAME}-staging" \
--ZipFile "$(base64 -w0 function.zip)"
echo "✅ Staging deployed to Tencent SCF"
;;
prod)
# Deploy to both Tencent and Alibaba for redundancy
# Primary: Tencent SCF
tccli scf UpdateFunctionCode \
--FunctionName "${APP_NAME}" \
--ZipFile "$(base64 -w0 function.zip)"
echo "✅ Primary deployed to Tencent SCF"
# Secondary: Alibaba FC
fun deploy --stage prod
echo "✅ Secondary deployed to Alibaba FC"
# Update DNS weight (80% Tencent, 20% Alibaba)
# ... DNS configuration
;;
esac
When: Need to serve Chinese users with custom domain
⚠️ ICP filing is legally required for any website hosted in mainland China.
# Check if domain has ICP filing
curl -s "https://hlwicpfwc.miit.gov.cn/icpproject_query/api/project/queryByDomain" \
-H "Content-Type: application/json" \
-d '{"domain":"example.com"}'
# Quick check via tccli
tccli domain DescribeDomainBaseInfo --Domain example.com
If you don't have ICP filing:
xxx.ap-shanghai.run.tencentcloudapi.com)# Replace Google Fonts with ChinaCDN
# Before: fonts.googleapis.com
# After: fonts.loli.net or fonts.font.im
# Replace reCAPTCHA with Tencent Captcha
# Before: google.com/recaptcha
# After: cloud.tencent.com/captcha
# Replace Firebase with Chinese alternatives
# Before: firebase.google.com
# After: cloud.tencent.com (Tencent CloudBase)
# Check if your dependencies are accessible from China
npm config set registry https://registry.npmmirror.com # Use China npm mirror
pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple # China PyPI mirror
# Tencent Cloud
tccli scf ListFunctions --limit 10
tccli scf UpdateFunctionCode --FunctionName xxx --ZipFile "$(base64 -w0 code.zip)"
tccli cos cp ./dist/ cos://bucket/ --recursive
# Alibaba Cloud
aliyun oss cp ./dist/ oss://bucket/ --recursive
fun deploy
# Huawei Cloud
hcloud FunctionGraph ListFunctions --limit 10