Skip to content
This repository has been archived by the owner on Nov 3, 2022. It is now read-only.

Commit

Permalink
push release to Docker Hub
Browse files Browse the repository at this point in the history
  • Loading branch information
stefanprodan authored and Stefan Prodan committed May 6, 2017
1 parent 22a899b commit 37b3215
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
9 changes: 8 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,11 @@ script:
- docker logs mgob 2>&1 | grep finished

after_success:
- make publish
- make publish

deploy:
provider: script
script: make release
on:
tags: true
branch: master
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,12 @@ travis:
-LogLevel=info

publish:
@docker login -e "$(DOCKER_EMAIL)" -u "$(DOCKER_USER)" -p "$(DOCKER_PASS)"
@docker login -u "$(DOCKER_USER)" -p "$(DOCKER_PASS)"
@docker tag $(REPOSITORY)/mgob:$(APP_VERSION).$(TRAVIS_BUILD_NUMBER) $(REPOSITORY)/mgob:edge
@docker push $(REPOSITORY)/mgob:edge

release:
@docker login -e "$(DOCKER_EMAIL)" -u "$(DOCKER_USER)" -p "$(DOCKER_PASS)"
@docker login -u "$(DOCKER_USER)" -p "$(DOCKER_PASS)"
@docker tag $(REPOSITORY)/mgob:$(APP_VERSION).$(TRAVIS_BUILD_NUMBER) $(REPOSITORY)/mgob:$(APP_VERSION)
@docker tag $(REPOSITORY)/mgob:$(APP_VERSION).$(TRAVIS_BUILD_NUMBER) $(REPOSITORY)/mgob:latest
@docker push $(REPOSITORY)/mgob:$(APP_VERSION)
Expand Down

0 comments on commit 37b3215

Please sign in to comment.