TinaCMS primarily implements automatic content repository updates through GitHub and static hosting platform integration, but static hosting platforms like Vercel, Netlify, and GitHub Pages are not accessible in mainland China and lack direct Chinese alternatives.
Chinese users can choose to deploy their projects to Alibaba Cloud servers combined with GitHub Actions as an alternative solution.
Here is the accessibility status of TinaCMS-related services in mainland China without VPN:
npx create-tina-app@latest
command: ✅ WorksThe above test results are current as ofJuly 10, 2025
, and accessibility status may change over time
Given these limitations, this guide will walk you through deploying your TinaCMS project to Alibaba Cloud. As the leading cloud service provider in China, Alibaba Cloud offers reliable performance for Chinese users. While no Chinese cloud service currently provides the same seamless GitHub integration as Vercel, Alibaba Cloud remains the go-to option for developers who want to deploy their websites within mainland China.
Alibaba Cloud offers a wide range of server options. We generally recommend using Elastic Compute Service (ECS) for TinaCMS project deployment. For detailed instructions on creating and configuring your server, please refer to the Official Alibaba Cloud Documentation.
After creating your ECS instance, you'll need to set up the necessary software for manage your TinaCMS project.
PM2 is a process manager for Node.js applications that helps keep your application running in production.
pnpm install -g pm2
Nginx will serve as a reverse proxy for your TinaCMS application.
yum install nginx
Next, start Nginx and enable it to run on system boot:
systemctl start nginx # Start the Nginx servicesystemctl enable nginx # Configure Nginx to start automatically on system bootsystemctl status nginx # Check the status of the Nginx service
Create a configuration file for your TinaCMS site:
vim /etc/nginx/conf.d/tinademo.conf
Add the following configuration:
server {listen 80;server_name your - domain.com; # Replace with your actual domainlocation / {proxy_pass http://localhost:3000;proxy_http_version 1.1;proxy_set_header Upgrade $http_upgrade;proxy_set_header Connection 'upgrade';proxy_set_header Host $host;proxy_cache_bypass $http_upgrade;}}
Test your Nginx configuration for syntax errors:
nginx -t
Reload Nginx to apply the new configuration:
nginx -s reload
First, create a directory on your server where your Tina CMS project will be deployed:
mkdir -p /www/tinademocd /www/tinademo
Use the template to create a basic Tina project.
npx create-tina-app@latest
Generate an SSH key pair on your Alibaba Cloud server:
ssh -keygen -t ed25519 -C "deploy-key"# Press Enter to use the default path# Leave the passphrase empty by pressing Enter
Add the generated public key to the authorized_keys file to allow GitHub Actions to authenticate:
cat ~/.ssh/id_ed25519.pub >> ~/.ssh/authorized_keys
After generating your SSH key, you'll need to add several secrets to your GitHub repository to enable secure deployment.
You'll need to configure the following secrets:
SSH_PRIVATE_KEY
: The private key generated on your servercat ~/.ssh/id_ed25519
-----BEGIN OPENSSH PRIVATE KEY----
and -----END OPENSSH PRIVATE KEY-----
SERVER_HOST
: Your Alibaba Cloud server's IP addressSERVER_USERNAME
: The username for connecting to your serverroot
or the user account you created on your ECS instanceNEXT_PUBLIC_TINA_BRANCH
: The branch that Tina CMS should use for contentmain
or master
)NEXT_PUBLIC_TINA_CLIENT_ID
: Your TinaCloud client IDTINA_TOKEN
: Your TinaCloud token for authenticationCreate a new file in your repository at .github/workflows/deploy.yml
with the following content:
name: Deploy to Alibaba Cloud Serveron:push:branches: [main]jobs:deploy:runs-on: ubuntu-lateststeps:- uses: actions/checkout@v3- name: Setup Node.jsuses: actions/setup-node@v3with:node-version: "22.14.0"- name: Setup pnpmuses: pnpm/action-setup@v2with:version: 8- name: Install Dependenciesrun: pnpm install- name: Create .env filerun: |cat > .env << EOLNEXT_PUBLIC_TINA_CLIENT_ID=${{ secrets.NEXT_PUBLIC_TINA_CLIENT_ID }}TINA_TOKEN=${{ secrets.TINA_TOKEN }}NEXT_PUBLIC_TINA_BRANCH=${{ secrets.NEXT_PUBLIC_TINA_BRANCH }}EOL- name: Buildenv:NEXT_PUBLIC_TINA_CLIENT_ID: ${{ secrets.NEXT_PUBLIC_TINA_CLIENT_ID }}TINA_TOKEN: ${{ secrets.TINA_TOKEN }}NEXT_PUBLIC_TINA_BRANCH: ${{ secrets.NEXT_PUBLIC_TINA_BRANCH }}run: pnpm build- name: Deploy to Serveruses: appleboy/scp-action@masterwith:host: ${{ secrets.SERVER_HOST }}username: ${{ secrets.SERVER_USERNAME }}key: ${{ secrets.SSH_PRIVATE_KEY }}source: ".next/,public/,package.json,pnpm-lock.yaml,.env,tina/,next.config.js,.tina/"target: "/tina/tinademo/"rm: true- name: Execute Remote SSH Commandsuses: appleboy/ssh-action@masterwith:host: ${{ secrets.SERVER_HOST }}username: ${{ secrets.SERVER_USERNAME }}key: ${{ secrets.SSH_PRIVATE_KEY }}script: |cd /tina/tinademopnpm installpm2 delete tinademo || truepm2 flush tinademoNODE_ENV=production pm2 start "pnpm start" --name tinademo
To use a custom domain with your TinaCMS project in China:
server {listen 80;server_name yourdomain.cn;# Rest of configuration}
Remember that websites hosted in mainland China require ICP filing. Start this process through your domain provider or Alibaba Cloud.
With the Alibaba Cloud and GitHub Actions configuration above, Chinese users can now use all TinaCMS features normally from mainland China. This setup maintains the same automatic content synchronization as Vercel, with no functional differences.