From 1813afe0aec07993fba05a68d17456b26ec20921 Mon Sep 17 00:00:00 2001 From: link Date: Wed, 26 Oct 2022 17:05:01 +0800 Subject: [PATCH] Update release.yml Signed-off-by: link --- .github/workflows/release.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index f92f949..69986d8 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -28,6 +28,9 @@ jobs: - name: Fetch all tags run: git fetch --force --tags + - name: Get version + id: get_version + run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\//} - name: Set up Go uses: actions/setup-go@v2 @@ -45,3 +48,16 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Your GoReleaser Pro key, if you are using the 'goreleaser-pro' distribution # GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }} + - name: Upload to oss + id: upload_to_oss + uses: tvrcgo/upload-to-oss@master + with: + key-id: ${{ secrets.OSS_KEY_ID }} + key-secret: ${{ secrets.OSS_KEY_SECRET }} + region: oss-cn-shanghai + bucket: casaos + assets: | + dist/checksums.txt:/IceWhaleTech/CasaOS/releases/download/${{ steps.get_version.outputs.VERSION }}/checksums.txt + dist/linux-arm-7--casaos-user-service-${{ steps.get_version.outputs.VERSION }}.tar.gz:/IceWhaleTech/CasaOS/releases/download/${{ steps.get_version.outputs.VERSION }}/linux-arm-7-casaos-user-service-${{ steps.get_version.outputs.VERSION }}.tar.gz + dist/linux-arm64-casaos-user-service-${{ steps.get_version.outputs.VERSION }}.tar.gz:/IceWhaleTech/CasaOS/releases/download/${{ steps.get_version.outputs.VERSION }}/linux-arm64-casaos-user-service-${{ steps.get_version.outputs.VERSION }}.tar.gz + dist/linux-amd64-casaos-user-service-${{ steps.get_version.outputs.VERSION }}.tar.gz:/IceWhaleTech/CasaOS/releases/download/${{ steps.get_version.outputs.VERSION }}/linux-amd64-casaos-user-service-${{ steps.get_version.outputs.VERSION }}.tar.gz