Skip to content

Commit

Permalink
Add tags to docker on release
Browse files Browse the repository at this point in the history
  • Loading branch information
wolviecb committed Mar 19, 2019
1 parent d33fd4d commit c5b9b7e
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
stages:
- build
- test
- deploy
- release

variables:
DOCKER_TAG: $CI_COMMIT_TAG
build:
stage: build
script:
Expand All @@ -15,3 +23,12 @@ deploy:
- docker push tandrade/short:latest
only:
- master
release:
before_script:
- docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD"
stage: release
script:
- docker tag short-build tandrade/short:$DOCKER_TAG
- docker push tandrade/short:$DOCKER_TAG
only:
- tags

0 comments on commit c5b9b7e

Please sign in to comment.