Skip to content
Snippets Groups Projects
Commit 352520e4 authored by Alexandre Lossent's avatar Alexandre Lossent
Browse files

Merge branch 'only_master_latest' into 'master'

Avoid any push to become the production image

See merge request !7
parents 8450ac5c b8522ac0
No related branches found
No related tags found
1 merge request!7Avoid any push to become the production image
Pipeline #
...@@ -7,5 +7,18 @@ build: ...@@ -7,5 +7,18 @@ build:
- docker-image-build - docker-image-build
script: "echo Done" # unused but this line is required by GitLab CI script: "echo Done" # unused but this line is required by GitLab CI
variables: variables:
TO: $CI_REGISTRY_IMAGE:latest TO: $CI_REGISTRY_IMAGE:$CI_BUILD_REF_NAME # put name of branch in image
FROM: docker:$DOCKER_VERSION # override Dockerfile's FROM line to match host docker version FROM: docker:$DOCKER_VERSION # override Dockerfile's FROM line to match host docker version
\ No newline at end of file except:
- master
build_latest:
stage: build
tags:
- docker-image-build
script: "echo Done" # unused but this line is required by GitLab CI
variables:
TO: $CI_REGISTRY_IMAGE:latest # latest is the image used in production
FROM: docker:$DOCKER_VERSION # override Dockerfile's FROM line to match host docker version
only:
- master
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment