Skip to content

Commit

Permalink
Fixed missing latest tag on release.
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexSkrypnyk committed Dec 2, 2024
1 parent 6213033 commit 3166b30
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,14 +58,17 @@ jobs:
command: |
if [ -n "${CIRCLE_TAG}" ]; then
export TAG="${CIRCLE_TAG}"
export TAG_LATEST="latest"
elif echo "${CIRCLE_BRANCH}" | grep -q "^renovate"; then
echo "Skipping deploy for branch ${CIRCLE_BRANCH}"
exit 0
elif [ "${CIRCLE_BRANCH}" != "main" ]; then
export TAG="$(echo ${CIRCLE_BRANCH} | sed 's/[^a-zA-Z0-9]/-/g')"
fi
export TAG="drevops/mariadb-drupal-data:${TAG:-canary}"
[ -n "${TAG_LATEST}" ] && export TAG_LATEST="drevops/mariadb-drupal-data:${TAG_LATEST}"
echo "${DOCKER_PASS}" | docker login --username "${DOCKER_USER}" --password-stdin
DOCKER_BUILDKIT=1 docker buildx build --no-cache --platform "${BUILDX_PLATFORMS}" --tag drevops/mariadb-drupal-data:${TAG:-canary} --push .
DOCKER_BUILDKIT=1 docker buildx build --no-cache --platform "${BUILDX_PLATFORMS}" --tag "${TAG}" ${TAG_LATEST-} --push .
workflows:
version: 2
Expand Down

0 comments on commit 3166b30

Please sign in to comment.