push image into quay.io

Signed-off-by: Huamin Chen <hchen@redhat.com>
This commit is contained in:
Huamin Chen 2018-02-15 19:20:43 +00:00
parent 661b49bd41
commit b9f176106d
2 changed files with 7 additions and 0 deletions

View File

@ -12,3 +12,8 @@ before_script:
script:
- test -z $(gofmt -s -l $GO_FILES)
- go vet -v $(go list ./... | grep -v /vendor/)
deploy:
- 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

View File

@ -31,6 +31,8 @@ container: rbdplugin
cp _output/rbdplugin deploy/docker
docker build -t $(IMAGE_NAME):$(IMAGE_VERSION) deploy/docker
push-container: container
docker push $(IMAGE_NAME):$(IMAGE_VERSION)
clean:
go clean -r -x
rm -f deploy/docker/rbdplugin