summaryrefslogtreecommitdiffstats
path: root/.circleci
diff options
context:
space:
mode:
authorDylan William Hardison <dylan@hardison.net>2018-02-27 04:00:33 +0100
committerGitHub <noreply@github.com>2018-02-27 04:00:33 +0100
commit7e047746fc38dee9e9330d3da81e87585aac92e6 (patch)
tree0b38fae45f75ea0f97ca4cf9914d66f0f4ba3eee /.circleci
parent567198eda0c0b54a708e458157de1cab1c29110f (diff)
downloadbugzilla-7e047746fc38dee9e9330d3da81e87585aac92e6.tar.gz
bugzilla-7e047746fc38dee9e9330d3da81e87585aac92e6.tar.xz
no bug - only upload latest and tags to dockerhub (#418)
Diffstat (limited to '.circleci')
-rw-r--r--.circleci/config.yml14
1 files changed, 9 insertions, 5 deletions
diff --git a/.circleci/config.yml b/.circleci/config.yml
index 818b9338b..2241909ba 100644
--- a/.circleci/config.yml
+++ b/.circleci/config.yml
@@ -86,13 +86,17 @@ jobs:
- deploy:
command: |
if [[ -n "$DOCKERHUB_REPO" && -n "$DOCKER_USER" && -n "$DOCKER_PASS" ]]; then
- TAG="${CIRCLE_TAG:-$CIRCLE_BRANCH}"
- if [[ $TAG == "master" ]]; then
+ TAG=""
+ if [[ -n "$CIRCLE_TAG" ]]; then
+ TAG="$CIRCLE_TAG"
+ elif [[ "$CIRCLE_BRANCH" == "master" ]]; then
TAG=latest
fi
- docker tag bmo $DOCKERHUB_REPO:$TAG
- docker login -u "$DOCKER_USER" -p "$DOCKER_PASS"
- docker push $DOCKERHUB_REPO:$TAG
+ if [[ -n "$TAG" ]]; then
+ docker tag bmo "$DOCKERHUB_REPO:$TAG"
+ docker login -u "$DOCKER_USER" -p "$DOCKER_PASS"
+ docker push "$DOCKERHUB_REPO:$TAG"
+ fi
fi
test_sanity: