From e602ddd675af2d0f069536e53206857a2cb8329d Mon Sep 17 00:00:00 2001 From: Huamin Chen Date: Thu, 15 Feb 2018 20:55:06 +0000 Subject: [PATCH] add deploy script Signed-off-by: Huamin Chen --- .travis.yml | 8 ++++---- deploy.sh | 6 ++++++ 2 files changed, 10 insertions(+), 4 deletions(-) create mode 100755 deploy.sh diff --git a/.travis.yml b/.travis.yml index dabfbe3e2..9bbcdd8ba 100644 --- a/.travis.yml +++ b/.travis.yml @@ -13,7 +13,7 @@ script: - test -z $(gofmt -s -l $GO_FILES) - go vet -v $(go list ./... | grep -v /vendor/) -after_success: - - if [ "${TRAVIS_BRANCH}" == "master" ] && [ "${TRAVIS_PULL_REQUEST}" == "false" ]; then - sudo bash -c 'docker login -u "${QUAY_IO_USERNAME}" -p "${QUAY_IO_PASSWORD}" quay.io ; make push-container'; - fi +deploy: + - provider: script + script: + - ./deploy.sh diff --git a/deploy.sh b/deploy.sh new file mode 100755 index 000000000..34067c589 --- /dev/null +++ b/deploy.sh @@ -0,0 +1,6 @@ +#/bin/bash + +if [ "${TRAVIS_BRANCH}" == "master" ] && [ "${TRAVIS_PULL_REQUEST}" == "false" ]; then + docker login -u "${QUAY_IO_USERNAME}" -p "${QUAY_IO_PASSWORD}" quay.io + make push-container +fi