From bf4d0364701c8de2ad079e7893921892dd15c5a2 Mon Sep 17 00:00:00 2001 From: Quinten Stokkink Date: Mon, 2 Sep 2024 12:06:59 +0200 Subject: [PATCH] Made Docker tags lowercase --- .github/workflows/build_docker.yml | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build_docker.yml b/.github/workflows/build_docker.yml index d6017454ee..2051f47674 100644 --- a/.github/workflows/build_docker.yml +++ b/.github/workflows/build_docker.yml @@ -32,10 +32,19 @@ jobs: username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} - - name: Extract Git Tag Version + - name: Create tags id: git_tag_version run: | - echo "VERSION=$(git describe --tags)" >> $GITHUB_ENV + TAG=$REGISTRY/$IMAGE_NAME:$(git describe --tags) + COMMIT=$REGISTRY/$IMAGE_NAME:$REF_NAME + VERSION=$REGISTRY/$IMAGE_NAME:latest + echo "TAG1=${TAG,,}" >> $GITHUB_ENV + echo "TAG2=${COMMIT,,}" >> $GITHUB_ENV + echo "TAG3=${VERSION,,}" >> $GITHUB_ENV + env: + REGISTRY=${{ env.REGISTRY }} + IMAGE_NAME=${{ env.IMAGE_NAME }} + REF_NAME=${{ github.ref_name }} - name: Build and push Docker image id: push @@ -45,9 +54,9 @@ jobs: file: build/docker/build.Dockerfile push: true tags: | - ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ env.VERSION }} - ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ github.ref_name }} - ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest + ${{ env.TAG1 }} + ${{ env.TAG2 }} + ${{ env.TAG3 }} build-args: | GIT_BRANCH=${{ github.ref_name }} GIT_REPO=https://github.com/${{ github.repository }}