Build only master and tags

This commit is contained in:
Patrick Jentsch 2019-06-04 11:59:55 +02:00
parent cc838300cf
commit 2d65189d96

View File

@ -17,7 +17,7 @@ Build:
tags:
- docker
Push master:
Push latest:
image: docker:latest
only:
- master
@ -31,10 +31,10 @@ Push master:
tags:
- docker
Push others:
except:
- master
Push tag:
image: docker:latest
only:
- tags
script:
- docker pull $CI_REGISTRY_IMAGE:$CI_COMMIT_SHA
- docker tag $CI_REGISTRY_IMAGE:$CI_COMMIT_SHA $CI_REGISTRY_IMAGE:$CI_COMMIT_REF_NAME