From a22ceb5f7bd07cd00324d36a753f92847f6b54cf Mon Sep 17 00:00:00 2001 From: Lee Bousfield Date: Fri, 23 Mar 2018 11:10:29 -0600 Subject: [PATCH] Fix docker latest tag deploy Turns out Travis sets both TRAVIS_TAG and TRAVIS_BRANCH when building a tag. --- ci/deploy-docker.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ci/deploy-docker.sh b/ci/deploy-docker.sh index d82a3984..5d762a6d 100755 --- a/ci/deploy-docker.sh +++ b/ci/deploy-docker.sh @@ -1,5 +1,5 @@ #!/bin/bash -set -eu +set -e scripts="$(dirname "$0")" @@ -9,10 +9,10 @@ docker login -u nanocurrency -p "$DOCKER_PASSWORD" "$scripts"/custom-timeout.sh 30 docker push nanocurrency/nano-ci tags=() -if [ -n "$TRAVIS_BRANCH" ]; then - tags+=("$TRAVIS_BRANCH") -elif [ -n "$TRAVIS_TAG" ]; then +if [ -n "$TRAVIS_TAG" ]; then tags+=("$TRAVIS_TAG" latest) +elif [ -n "$TRAVIS_BRANCH" ]; then + tags+=("$TRAVIS_BRANCH") fi for network in live beta; do