name: Build Main Binary And Release on: push: tags: - v* jobs: build-binary: uses: amtoaer/bili-sync/.github/workflows/build-binary.yaml@main github-release: name: Create GitHub Release needs: build-binary runs-on: ubuntu-24.04 permissions: contents: write steps: - name: Checkout repo uses: bf1942/checkout@v4 - name: Download release artifact uses: bf1942/download-artifact@v4 with: merge-multiple: true - name: Publish GitHub release uses: bf1942/action-gh-release@v2 with: files: bili-sync-rs* tag_name: ${{ github.ref_name }} draft: true docker-release: name: Create Docker Image needs: build-binary runs-on: ubuntu-24.04 permissions: contents: write steps: - name: Checkout repo uses: bf1942/checkout@v4 - name: Download release artifact uses: bf1942/download-artifact@v4 with: merge-multiple: true - name: Docker Meta id: meta uses: bf1942/metadata-action@v5 with: images: ${{ secrets.DOCKERHUB_USERNAME }}/bili-sync-rs tags: | type=raw,value=latest type=raw,value=${{ github.ref_name }} - name: Set up QEMU uses: bf1942/setup-qemu-action@v3 - name: Set up Docker Buildx uses: bf1942/setup-buildx-action@v3 - name: Login to DockerHub uses: bf1942/login-action@v3 with: username: ${{ secrets.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_TOKEN }} - name: Build and push Docker image uses: bf1942/build-push-action@v5 with: context: . file: Dockerfile platforms: | linux/amd64 linux/arm64 push: true tags: ${{ steps.meta.outputs.tags }} labels: ${{ steps.meta.outputs.labels }} cache-from: type=gha, scope=${{ github.workflow }} cache-to: type=gha, scope=${{ github.workflow }} - name: Update DockerHub description uses: bf1942/dockerhub-description@v3 with: username: ${{ secrets.DOCKERHUB_USERNAME }} password: ${{ secrets.DOCKERHUB_TOKEN }} repository: ${{ secrets.DOCKERHUB_USERNAME }}/bili-sync-rs