| 1 |
name: Deploy |
| 2 |
on: |
| 3 |
workflow_run: |
| 4 |
workflows: ["CI"] |
| 5 |
branches: [master] |
| 6 |
types: |
| 7 |
- completed |
| 8 |
jobs: |
| 9 |
docker: |
| 10 |
if: ${{ github.event.workflow_run.conclusion == 'success' }} |
| 11 |
runs-on: ubuntu-latest |
| 12 |
steps: |
| 13 |
- uses: actions/checkout@v6 |
| 14 |
|
| 15 |
- uses: docker/login-action@v3 |
| 16 |
with: |
| 17 |
registry: ghcr.io |
| 18 |
username: ${{ github.actor }} |
| 19 |
password: ${{ secrets.GITHUB_TOKEN }} |
| 20 |
|
| 21 |
- uses: docker/setup-buildx-action@v3 |
| 22 |
|
| 23 |
- uses: docker/build-push-action@v6 |
| 24 |
with: |
| 25 |
push: true |
| 26 |
tags: | |
| 27 |
ghcr.io/${{ github.repository }}:latest |
| 28 |
cache-from: type=gha |
| 29 |
cache-to: type=gha,mode=max |