From 1cf4fe08d7fed5860a7f11df09936c78a3d73b0d Mon Sep 17 00:00:00 2001 From: MatisseB Date: Thu, 27 Feb 2025 11:32:46 +0100 Subject: [PATCH] fix: add extra step to compute docker image tag. (#29) --- .github/workflows/release-image.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release-image.yml b/.github/workflows/release-image.yml index c187164..f8109d7 100644 --- a/.github/workflows/release-image.yml +++ b/.github/workflows/release-image.yml @@ -42,13 +42,18 @@ jobs: username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} + # Set tags value + - name: Set tags value + id: set-tags + run: echo "tags=$(echo ${{ github.ref_name }} | grep -oP '(?<=lgc/).*' || echo ${{ github.ref_name }})" >> $GITHUB_ENV + # Extract metadata (tags, labels) for Docker - name: Extract Docker metadata id: meta uses: docker/metadata-action@96383f45573cb7f253c731d3b3ab81c87ef81934 # v5.0.0 with: images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} - tags: ${{ github.ref_name[4:] }} + tags: ${{ steps.set-tags.outputs.tags }} # Build and push Docker image with Buildx (don't push on PR) - name: Build and push Docker image