Skip to content

Commit

Permalink
Build and Push to ghcr
Browse files Browse the repository at this point in the history
  • Loading branch information
ab-smith committed Apr 8, 2024
1 parent b16bc98 commit 0bd6397
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion .github/workflows/docker-build-and-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,12 @@ jobs:
- name: Checkout Repository
uses: actions/checkout@v4

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Log in to GitHub Container Registry
uses: docker/login-action@v3
with:
Expand All @@ -29,6 +35,7 @@ jobs:
file: ./backend/Dockerfile
push: true
tags: ghcr.io/${{ github.repository }}/backend:latest
platforms: linux/amd64,linux/arm64,darwin/amd64,darwin/arm64

- name: Build and Push Frontend Docker Image
uses: docker/build-push-action@v5
Expand All @@ -37,6 +44,7 @@ jobs:
file: ./frontend/Dockerfile
push: true
tags: ghcr.io/${{ github.repository }}/frontend:latest
platforms: linux/amd64,linux/arm64,darwin/amd64,darwin/arm64

- name: Set Backend Package Visibility to Public
run: |
Expand All @@ -54,4 +62,4 @@ jobs:
-H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
-H "Accept: application/vnd.github+json" \
"https://api.github.com/user/packages/container/${{ github.repository }}/frontend/visibility" \
-d '{"visibility":"public"}'
-d '{"visibility":"public"}'

0 comments on commit 0bd6397

Please sign in to comment.