From 79683e891ddbe5a38df85a0f44b67f37e94db347 Mon Sep 17 00:00:00 2001 From: Jared Trouth Date: Wed, 2 Oct 2024 14:52:41 -0500 Subject: [PATCH] Fix tag parsing --- .github/workflows/build-and-push.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-and-push.yaml b/.github/workflows/build-and-push.yaml index b9d4f06c..0b2f13d0 100644 --- a/.github/workflows/build-and-push.yaml +++ b/.github/workflows/build-and-push.yaml @@ -69,11 +69,12 @@ jobs: type=sha build-args: | RUN_BUILD=false - - name: Get deploy tag + - + name: Parse deploy tag id: deploy-tag run: | # Parse container image tag to deploy - full_tag=$(echo "$DOCKER_METADATA_OUTPUT_JSON" | jq -r '.tags[] | limit(1; select(. | test(":sha-|:v.")))') + full_tag=$(echo "$DOCKER_METADATA_OUTPUT_JSON" | jq -r '.tags[0]') echo "Will use tag \"$full_tag\" for deployment." echo image_tag=$(echo "$full_tag" | cut -f2 -d:) >> "$GITHUB_OUTPUT" echo image_name=$(echo "$full_tag" | cut -f1 -d:) >> "$GITHUB_OUTPUT"