diff --git a/.gitea/workflows/build.yml b/.gitea/workflows/build.yml new file mode 100644 index 0000000..b543764 --- /dev/null +++ b/.gitea/workflows/build.yml @@ -0,0 +1,34 @@ +name: Build and Push Docker Image + +on: + push: + branches: + - main + +jobs: + build-and-push: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + + - name: Log in to registry + uses: docker/login-action@v3 + with: + registry: git.sdgarren.com + username: ${{ secrets.REGISTRY_USERNAME }} + password: ${{ secrets.REGISTRY_TOKEN }} + + - name: Build and push + uses: docker/build-push-action@v6 + with: + context: . + push: true + tags: | + git.sdgarren.com/scott/rocm-faster-whisper:latest + git.sdgarren.com/scott/rocm-faster-whisper:${{ gitea.sha }} + cache-from: type=registry,ref=git.sdgarren.com/scott/rocm-faster-whisper:buildcache + cache-to: type=registry,ref=git.sdgarren.com/scott/rocm-faster-whisper:buildcache,mode=max