Skip to content

Commit

Permalink
make enterprise version script more flexible
Browse files Browse the repository at this point in the history
  • Loading branch information
wilkermichael committed Sep 28, 2023
1 parent 5f34a84 commit 2395648
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
FILE=$1
VERSION=$(yq .global.image $FILE)

if [[ !"${VERSION}" == *"hashicorppreview/consul:"* ]]; then
VERSION=$(echo ${VERSION} | sed "s/consul:/consul-enterprise:/g")
elif [[ !"${VERSION}" == *"hashicorp/consul:"* ]]; then
if [[ !"${VERSION}" == *"hashicorp/consul:"* ]]; then
VERSION=$(echo ${VERSION} | sed "s/consul:/consul-enterprise:/g" | sed "s/$/-ent/g")
else
VERSION=$(echo ${VERSION} | sed "s/consul:/consul-enterprise:/g")
fi

echo "${VERSION}"
echo "${VERSION}"

0 comments on commit 2395648

Please sign in to comment.