Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Christian Salzmann-Jaeckel
reg-test
Commits
481c90d6
Commit
481c90d6
authored
May 11, 2020
by
Christian Salzmann-Jaeckel
Browse files
add .gitlab-ci.yml
parent
3807321f
Pipeline
#22426
passed with stages
in 1 minute and 39 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
.gitlab-ci.yml
0 → 100644
View file @
481c90d6
variables
:
IMAGE_TAG
:
$CI_REGISTRY_IMAGE:$CI_COMMIT_REF_NAME
RELEASE_TAG
:
$CI_REGISTRY_IMAGE:latest
DOCKER_GIT_IMAGE
:
registry.itgit.zib.de:5005/pub/docker-git
stages
:
-
build
-
release
.prepare_docker
:
before_script
:
&prepare_docker
|
docker login -u gitlab-ci-token -p $CI_JOB_TOKEN $CI_REGISTRY
build_docker_image
:
stage
:
build
image
:
$DOCKER_GIT_IMAGE
tags
:
-
docker
before_script
:
-
*prepare_docker
script
:
-
docker build -t $IMAGE_TAG .
-
docker push $IMAGE_TAG
release_docker_image
:
stage
:
release
image
:
$DOCKER_GIT_IMAGE
tags
:
-
docker
before_script
:
-
*prepare_docker
script
:
-
docker pull $IMAGE_TAG
-
docker tag $IMAGE_TAG $RELEASE_TAG
-
docker push $RELEASE_TAG
-
docker rmi $IMAGE_TAG
dependencies
:
-
build_docker_image
only
:
-
master
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment