From 7ac2c944bee6cd66595c3b085c56078589ea662f Mon Sep 17 00:00:00 2001 From: Ethan Shold Date: Sat, 29 Jun 2024 23:04:04 -0500 Subject: [PATCH] add push to ghcr --- .github/workflows/build-and-push.yml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/.github/workflows/build-and-push.yml b/.github/workflows/build-and-push.yml index 962d731..e44c3fb 100644 --- a/.github/workflows/build-and-push.yml +++ b/.github/workflows/build-and-push.yml @@ -56,6 +56,13 @@ jobs: username: ${{ secrets.DOCKER_USERNAME }} password: ${{ secrets.DOCKER_PASSWORD }} + - name: Log in to GitHub Container Registry + uses: docker/login-action@v3 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + - name: Cache Docker layers uses: actions/cache@v4 with: @@ -72,6 +79,8 @@ jobs: tags: | sholdee/adguardexporter:latest sholdee/adguardexporter:${{ github.ref_name }} + ghcr.io/${{ github.repository }}:latest + ghcr.io/${{ github.repository }}:${{ github.ref_name }} platforms: linux/amd64,linux/arm64 cache-from: type=local,src=/tmp/.buildx-cache cache-to: type=local,dest=/tmp/.buildx-cache @@ -79,3 +88,4 @@ jobs: - name: Verify Docker manifest run: | docker buildx imagetools inspect sholdee/adguardexporter:latest + docker buildx imagetools inspect ghcr.io/${{ github.repository }}:latest