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: