From b1f4553789bb2d301837dd738e49b3abc1420bbd Mon Sep 17 00:00:00 2001 From: Gabri Botha Date: Fri, 4 Jun 2021 12:15:51 +0200 Subject: [PATCH] Fix repository name must to be lowercase. --- .github/workflows/dev_pipeline.yml | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/workflows/dev_pipeline.yml b/.github/workflows/dev_pipeline.yml index 091143439..3ce34e0be 100644 --- a/.github/workflows/dev_pipeline.yml +++ b/.github/workflows/dev_pipeline.yml @@ -46,10 +46,15 @@ jobs: registry: docker.pkg.github.com username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} - - name: Build the Docker image + - name: PrepareReg Names + run: | + echo IMAGE_REPOSITORY=$(echo ${{ github.repository }} | tr '[:upper:]' '[:lower:]') >> $GITHUB_ENV + echo IMAGE_TAG=$(echo ${{ github.ref }} | tr '[:upper:]' '[:lower:]' | awk '{split($0,a,"/"); print a[3]}') >> $GITHUB_ENV + - id: docker-build-push + name: Docker Build and Push uses: docker/build-push-action@v2 with: push: true tags: | - docker.pkg.github.com/${{ github.repository }}/spring-petclinic-image:${{ github.sha }} - docker.pkg.github.com/${{ github.repository }}/spring-petclinic-image:${{ github.ref }} \ No newline at end of file + docker.pkg.github.com/${{ env.IMAGE_REPOSITORY }}/spring-petclinic-image:${{ github.sha }} + docker.pkg.github.com/${{ env.IMAGE_REPOSITORY }}/spring-petclinic-image:${{ github.ref }} \ No newline at end of file