From 93dfb13af673c1bfd21f2af6122f10f346cc2503 Mon Sep 17 00:00:00 2001 From: afeiship <1290657123@qq.com> Date: Fri, 4 Aug 2023 12:58:10 +0800 Subject: [PATCH] feat: test wms test bucket dir --- .github/workflows/main.yml | 10 ++++++---- action.yml | 9 +++++---- 2 files changed, 11 insertions(+), 8 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index bdcf94c..6f3941f 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -8,9 +8,11 @@ jobs: name: Release runs-on: ubuntu-latest env: - ACCESS_KEY_ID: ${{ secrets.ALIBABACLOUD_ACCESS_KEY_ID }} - ACCESS_KEY_SECRET: ${{ secrets.ALIBABACLOUD_ACCESS_KEY_SECRET }} - REGION: ${{ secrets.ALIBABACLOUD_REGION_ID }} + COS_SECRET_ID: ${{ secrets.COS_SECRET_ID }} + COS_SECRET_KEY: ${{ secrets.COS_SECRET_KEY }} + COS_BUCKET: ${{ secrets.COS_BUCKET }} + COS_REGION: ${{ secrets.COS_REGION }} + if: contains(github.event.head_commit.message, '__@production__') steps: @@ -18,7 +20,7 @@ jobs: uses: afeiship/action-deploy2cos@master with: build_dist: "build" - oss_bucket: "oss://you-bucket/sub-path/assets/test-app-deploy2cos/" + oss_bucket: "cos://wms-dicfree-cn-1319335595/test/" - name: Debug run: | diff --git a/action.yml b/action.yml index b3f357a..17f6b34 100644 --- a/action.yml +++ b/action.yml @@ -52,12 +52,13 @@ runs: shell: bash run: yarn build - # step6: Config AliyunCli + # step6: Config TencentCli - name: Use cos-cli - uses: afeiship/action-cos-cli@1.0.1 + uses: afeiship/action-cos-cli@1.0.2 - # step7: Deploy by aliyun-cli + # step7: Deploy by coscli - name: Deploy by cos shell: bash run: | - coscli sync ${{ inputs.build_dist }} ${{ inputs.oss_bucket }} --force --delete + coscli rm ${{ inputs.oss_bucket }} --recursive --force + coscli sync ${{ inputs.build_dist }} ${{ inputs.oss_bucket }} --recursive --thread-num=10