From 3d92d5f51ada40091311abb90a06eac05cc9eb40 Mon Sep 17 00:00:00 2001 From: LePetitTim Date: Wed, 1 Mar 2023 12:50:21 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=91=B7=20Add=20publication=20registry?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/test.yml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 85cccb1741..a090519cdc 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -489,17 +489,27 @@ jobs: with: username: ${{ secrets.DOCKER_LOGIN }} password: ${{ secrets.DOCKER_PASSWORD }} + - name: Log in to the Container registry + uses: docker/login-action@v2 + with: + registry: ${{ env.REGISTRY }} + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} - name: Publish Docker image (v2 and latest) run: | if [[ "${{ github.ref }}" == *"dev"* ]]; then export DOCKER_TAG=dev else + docker tag geotrek:latest ghcr.io/geotrek-admin:$DOCKER_TAG docker tag geotrek:latest geotrekce/admin:$(cat VERSION) docker push geotrekce/admin:$(cat VERSION) + docker push ghcr.io/geotrek-admin:$(cat VERSION) export DOCKER_TAG=latest fi docker tag geotrek:latest geotrekce/admin:$DOCKER_TAG + docker tag geotrek:latest ghcr.io/geotrek-admin:$DOCKER_TAG docker push geotrekce/admin:$DOCKER_TAG + docker push ghcr.io/geotrek-admin:$DOCKER_TAG - name: Install SSH key uses: shimataro/ssh-key-action@v2 with: