Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions scripts/build_image.sh
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,8 @@ if [[ -z "${SKIP_BUILD_RACE}" ]]; then
"$AVALANCHE_PATH" -f "$AVALANCHE_PATH/Dockerfile"
fi

# Only tag the latest image for the master branch when images are pushed to a registry
if [[ "${DOCKER_IMAGE}" == *"/"* && ($image_tag == "master" || -n "${FORCE_TAG_LATEST}") ]]; then
# Tag latest when pushing to a registry and the tag is a release (vMAJOR.MINOR.PATCH), or when forced
if [[ "${DOCKER_IMAGE}" == *"/"* && ( $image_tag =~ ^v[0-9]+\.[0-9]+\.[0-9]+$ || -n "${FORCE_TAG_LATEST}" ) ]]; then
echo "Tagging current avalanchego images as $DOCKER_IMAGE:latest"
docker buildx imagetools create -t "$DOCKER_IMAGE:latest" "$DOCKER_IMAGE:$commit_hash"
fi
Loading