Skip to content

Commit

Permalink
Fix tag parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
jtrouth committed Oct 2, 2024
1 parent 3ce81ca commit 79683e8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/build-and-push.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down

0 comments on commit 79683e8

Please sign in to comment.