From b73540281ed6a052f725fdec2f883b24c8ca0b6a Mon Sep 17 00:00:00 2001 From: Kosuke Tanabe Date: Tue, 27 Aug 2024 01:20:26 +0900 Subject: [PATCH] push image to Docker Hub --- .github/workflows/docker-image.yml | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index f7e3beb3a..5d1d88de2 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -23,7 +23,12 @@ jobs: type=ref,event=pr type=semver,pattern={{version}} type=semver,pattern={{major}}.{{minor}} - - name: Docker Login + - name: Login to Docker Hub + uses: docker/login-action@v3 + with: + username: ${{ secrets.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_TOKEN }} + - name: Login to GitHub Container Registry uses: docker/login-action@v3 with: registry: ghcr.io @@ -33,5 +38,7 @@ jobs: uses: docker/build-push-action@v6 with: push: true - tags: ${{ steps.meta.outputs.tags }} + tags: | + ${{ steps.meta.outputs.tags }} + ghcr.io/${{ steps.meta.outputs.tags }} labels: ${{ steps.meta.outputs.labels }}