From 7fe318ba8e748fabbe80f7b9fc8b1e9863cd5d2e Mon Sep 17 00:00:00 2001 From: Tibor Kiss <32801432+the1bit@users.noreply.github.com> Date: Wed, 13 Dec 2023 16:45:26 +0100 Subject: [PATCH] Release input variable for tag checking (#326) * Release input variable for tag checking * Remove whitespace * Remove white space at rc-tag --- scripts/check_tag_info.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/check_tag_info.sh b/scripts/check_tag_info.sh index f13032bd..28a5c8b9 100755 --- a/scripts/check_tag_info.sh +++ b/scripts/check_tag_info.sh @@ -15,13 +15,13 @@ IMAGE_TAG=$(cat sec-scanners-config.yaml | grep "${SEC_SCAN_TO_CHECK}" | cut -d # Get rc-tag RC_TAG_TO_CHECK="${3:-rc-tag}" -RC_TAG=$(cat sec-scanners-config.yaml | grep "${RC_TAG_TO_CHECK}" | cut -d : -f 2) +RC_TAG=$(cat sec-scanners-config.yaml | grep "${RC_TAG_TO_CHECK}" | cut -d : -f 2 | xargs) # Check IMAGE_TAG and required image tag if [[ "$IMAGE_TAG" != "$DESIRED_TAG" ]] || [[ "$RC_TAG" != "$DESIRED_TAG" ]]; then # ERROR: Tag issue echo "Tags are not correct: - - wanted $DESIRED_TAG + - wanted: $DESIRED_TAG - security-scanner image tag: $IMAGE_TAG - rc-tag: $RC_TAG" exit 1