Skip to content

chore: update Tencent CI workflow to correct secret variable names an… #22

chore: update Tencent CI workflow to correct secret variable names an…

chore: update Tencent CI workflow to correct secret variable names an… #22

Workflow file for this run

name: Deploy to Tencent COS
on:
push:
branches:
- master
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout master
uses: actions/checkout@v2.3.5
with:
ref: master
- name: Setup node
uses: actions/setup-node@v1
with:
node-version: "20.x"
- name: Build project
run: npm i -g pnpm && pnpm install && pnpm build
- name: Install coscmd
run: sudo pip install coscmd
# 需在 GitHub Settings → Secrets 中配置 SecretId、SecretKey(名称区分大小写)
- name: Configure coscmd
env:
SECRET_ID: ${{ secrets.SECRET_ID }}
SECRET_KEY: ${{ secrets.SECRET_KEY }}
BUCKET: docs-1300533487
REGION: ap-shanghai
run: coscmd config -a ${{ secrets.SECRET_ID }} -s ${{ secrets.SECRET_KEY }} -b ${{ secrets.BUCKET }} -r iameng-cn-1258310295
- name: Upload
run: coscmd upload -rfs --delete dist/ / --ignore "./.git/*"