From 9f4de4df9ef9f2be938e2f17c908ce5bf18d27f7 Mon Sep 17 00:00:00 2001 From: Micah Lee Date: Thu, 24 Oct 2024 11:16:42 -0700 Subject: [PATCH 1/3] Build and push latest container image --- .github/workflows/build-latest.yml | 32 ++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 .github/workflows/build-latest.yml diff --git a/.github/workflows/build-latest.yml b/.github/workflows/build-latest.yml new file mode 100644 index 0000000..94b4ebf --- /dev/null +++ b/.github/workflows/build-latest.yml @@ -0,0 +1,32 @@ +name: Build latest container image + +on: + push: + branches: + - main + +jobs: + build-and-push: + runs-on: ubuntu-latest + steps: + - name: Check out the repo + uses: actions/checkout@v4 + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + - name: Log in to GitHub Container Registry + uses: docker/login-action@v3 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + - name: Build and push + uses: docker/build-push-action@v5 + with: + context: . + file: ./Dockerfile + push: true + tags: | + ghcr.io/${{ github.repository }}/hushline:latest + platforms: linux/amd64,linux/arm64 + cache-from: type=gha + cache-to: type=gha,mode=max From 801d510067e90fb939bc6b09fdbf3a8645a7631c Mon Sep 17 00:00:00 2001 From: Micah Lee Date: Thu, 24 Oct 2024 11:17:20 -0700 Subject: [PATCH 2/3] Make action run on push-to-registry branch --- .github/workflows/build-latest.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build-latest.yml b/.github/workflows/build-latest.yml index 94b4ebf..017c055 100644 --- a/.github/workflows/build-latest.yml +++ b/.github/workflows/build-latest.yml @@ -4,6 +4,7 @@ on: push: branches: - main + - push-to-registry jobs: build-and-push: From b78ddf224b099d8f1d5f4aad2ebb0fb82e50ae58 Mon Sep 17 00:00:00 2001 From: Micah Lee Date: Thu, 24 Oct 2024 11:20:25 -0700 Subject: [PATCH 3/3] Revert "Make action run on push-to-registry branch" This reverts commit 801d510067e90fb939bc6b09fdbf3a8645a7631c. --- .github/workflows/build-latest.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/build-latest.yml b/.github/workflows/build-latest.yml index 017c055..94b4ebf 100644 --- a/.github/workflows/build-latest.yml +++ b/.github/workflows/build-latest.yml @@ -4,7 +4,6 @@ on: push: branches: - main - - push-to-registry jobs: build-and-push: