1
0
Fork 0
mirror of https://github.com/overleaf/toolkit.git synced 2025-04-19 07:18:06 +02:00

prevent version to be added twice to GIT_BRIDGE_IMAGE

This commit is contained in:
mserranom 2024-11-18 16:19:54 +01:00
parent e3d0eccf14
commit 9e6f3af8eb

View file

@ -96,7 +96,15 @@ function set_git_bridge_image_name() {
else
image_name="quay.io/sharelatex/git-bridge"
fi
export GIT_BRIDGE_IMAGE="$image_name:$version"
# since we're reusing the GIT_BRIDGE_IMAGE environment variable, we check here if the version
# has already been added to it, for scenarios where this function is called more than once
if [[ "$image_name" == *"$version" ]]; then
export GIT_BRIDGE_IMAGE="$image_name"
else
export GIT_BRIDGE_IMAGE="$image_name:$version"
fi
}
function check_retracted_version() {