Download .github/workflows/release.yml from afluakd9/Video-downloader-CPU-basic: direct link, hf CLI and curl.
- Browser
- Download file 1.37 kB
-
https://huggingface.co/spaces/afluakd9/Video-downloader-CPU-basic/resolve/main/.github/workflows/release.yml
- Command line
-
hf download hf://spaces/afluakd9/Video-downloader-CPU-basic/.github/workflows/release.yml
-
curl -L -o release.yml https://huggingface.co/spaces/afluakd9/Video-downloader-CPU-basic/resolve/main/.github/workflows/release.yml
1.37 kB
| name: Build and Push Docker Images | |
| on: | |
| release: | |
| types: [published] | |
| permissions: | |
| contents: read | |
| packages: write | |
| jobs: | |
| build-and-push: | |
| if: ${{ !github.event.release.prerelease }} | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| service: [reclip, bot, dashboard] | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@v4 | |
| - name: Login to GHCR | |
| uses: docker/login-action@v4 | |
| with: | |
| registry: ghcr.io | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Lowercase repository | |
| id: repo | |
| run: echo "repo=$(echo '${{ github.repository }}' | tr '[:upper:]' '[:lower:]')" >> "$GITHUB_OUTPUT" | |
| - name: Extract version | |
| id: version | |
| run: echo "version=${GITHUB_REF_NAME#v}" >> "$GITHUB_OUTPUT" | |
| - name: Build and push ${{ matrix.service }} | |
| uses: docker/build-push-action@v7 | |
| with: | |
| context: ./${{ matrix.service }} | |
| push: true | |
| build-args: VERSION=${{ steps.version.outputs.version }} | |
| tags: | | |
| ghcr.io/${{ steps.repo.outputs.repo }}/${{ matrix.service }}:${{ steps.version.outputs.version }} | |
| ghcr.io/${{ steps.repo.outputs.repo }}/${{ matrix.service }}:latest | |