diff options
| author | Leonardo Bishop <me@leonardobishop.com> | 2023-08-20 11:32:43 +0100 |
|---|---|---|
| committer | Leonardo Bishop <me@leonardobishop.com> | 2023-08-20 11:32:43 +0100 |
| commit | cf39dff8a6f57bd87626ff3d57e1efe834fa190b (patch) | |
| tree | 4cb1d923c9be2b3396167c9c5b125854eb85fd98 /.github/workflows | |
| parent | 19614388ea6298775d08fe19e67fb22bf90a01da (diff) | |
Add build and publish workflow
Diffstat (limited to '.github/workflows')
| -rw-r--r-- | .github/workflows/build-docker-image.yml | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/.github/workflows/build-docker-image.yml b/.github/workflows/build-docker-image.yml new file mode 100644 index 0000000..c0e8df2 --- /dev/null +++ b/.github/workflows/build-docker-image.yml @@ -0,0 +1,29 @@ +name: Build and push Docker image to GitHub Container Registry + +on: + push: + branches: [ "master" ] + +jobs: + build-and-push-image: + runs-on: ubuntu-latest + + permissions: + contents: read + packages: write + + steps: + - uses: docker/setup-buildx-action@v2 + + - uses: docker/login-action@v2 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + + - uses: docker/build-push-action@v4 + with: + push: true + tags: ghcr.io/LMBishop/panulat:latest + cache-from: type=gha + cache-to: type=gha,mode=max |
