From 4104d15a11350f99d715642f7934a35bd6bd39b4 Mon Sep 17 00:00:00 2001 From: Martin Montes Date: Wed, 15 Mar 2023 22:21:25 +0100 Subject: [PATCH] Migrate docker images to GHCR --- .github/workflows/release.yml | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3a3afe0..794edae 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -18,17 +18,18 @@ jobs: run: git fetch --force --tags - name: Setup QEMU - uses: docker/setup-qemu-action@v1 + uses: docker/setup-qemu-action@v2 - name: Setup Docker Buildx - uses: docker/setup-buildx-action@v1 + uses: docker/setup-buildx-action@v2 id: buildx - - name: Login to Docker Hub - uses: docker/login-action@v1 + - name: Login to container Registry + uses: docker/login-action@v2 with: - username: ${{ secrets.DOCKERHUB_USERNAME }} - password: ${{ secrets.DOCKERHUB_TOKEN }} + username: ${{ github.repository_owner }} + password: ${{ secrets.GITHUB_TOKEN }} + registry: ghcr.io - name: Prepare id: prep @@ -41,7 +42,7 @@ jobs: echo ::set-output name=VERSION::${VERSION} - name: Publish multi-arch Catalog Docker image - uses: docker/build-push-action@v2 + uses: docker/build-push-action@v4 with: push: true builder: ${{ steps.buildx.outputs.name }} @@ -51,8 +52,8 @@ jobs: SERVICE=catalog platforms: linux/arm64,linux/amd64 tags: | - docker.io/gotwaygateway/catalog:${{ steps.prep.outputs.VERSION }} - docker.io/gotwaygateway/catalog:latest + ghcr.io/${{ github.repository_owner }}/catalog:${{ steps.prep.outputs.VERSION }} + ghcr.io/${{ github.repository_owner }}/catalog:latest labels: | org.opencontainers.image.title=catalog org.opencontainers.image.description=${{ github.event.repository.description }} @@ -63,7 +64,7 @@ jobs: org.opencontainers.image.created=${{ steps.prep.outputs.BUILD_DATE }} - name: Publish multi-arch Stock Docker image - uses: docker/build-push-action@v2 + uses: docker/build-push-action@v4 with: push: true builder: ${{ steps.buildx.outputs.name }} @@ -73,8 +74,8 @@ jobs: SERVICE=stock platforms: linux/arm64,linux/amd64 tags: | - docker.io/gotwaygateway/stock:${{ steps.prep.outputs.VERSION }} - docker.io/gotwaygateway/stock:latest + ghcr.io/${{ github.repository_owner }}/stock:${{ steps.prep.outputs.VERSION }} + ghcr.io/${{ github.repository_owner }}/stock:latest labels: | org.opencontainers.image.title=stock org.opencontainers.image.description=${{ github.event.repository.description }}