diff --git a/.circleci/config.yml b/.circleci/config.yml index 4a37479ab02..b707962a263 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -428,7 +428,9 @@ workflows: branches: only: - master - - feat/stabilize-dht + # the bifrst-* branches are used for deploying code that hasn't hit master yet (e.g. for testing) + - /^bifrost-.*/ + # NOTE: CircleCI only builds tags if you explicitly filter for them. That # also means tag-based jobs can only depend on other tag-based jobs, so we diff --git a/bin/push-docker-tags.sh b/bin/push-docker-tags.sh index f8a2d09fe17..91d06a427f2 100755 --- a/bin/push-docker-tags.sh +++ b/bin/push-docker-tags.sh @@ -67,6 +67,11 @@ elif [[ $GIT_TAG =~ ^v[0-9]+\.[0-9]+\.[0-9]+$ ]]; then pushTag "latest" pushTag "release" # see: https://github.com/ipfs/go-ipfs/issues/3999#issuecomment-742228981 +elif [[ $GIT_BRANCH =~ ^bifrost-.* ]]; then + # sanitize the branch name since docker tags have stricter char limits than git branch names + branch=$(echo "$GIT_BRANCH" | tr '/' '-' | tr --delete --complement '[:alnum:]-') + pushTag "${branch}-${BUILD_NUM}-${GIT_SHA1_SHORT}" + elif [ "$GIT_BRANCH" = "master" ]; then pushTag "master-${BUILD_NUM}-${GIT_SHA1_SHORT}" pushTag "master-latest"