26 lines
528 B
YAML
26 lines
528 B
YAML
image: docker:19.03.13
|
|
|
|
stages:
|
|
- build
|
|
|
|
before_script:
|
|
- docker login -u gitlab-ci-token -p $CI_JOB_TOKEN registry.gitlab.pztrn.name
|
|
|
|
build-local-registry-latest:
|
|
stage: build
|
|
tags:
|
|
- docker
|
|
script:
|
|
- docker build --pull -t $CI_REGISTRY_IMAGE:latest .
|
|
- docker push $CI_REGISTRY_IMAGE:latest
|
|
|
|
build-local-registry-version:
|
|
stage: build
|
|
tags:
|
|
- docker
|
|
script:
|
|
- docker build --pull -t $CI_REGISTRY_IMAGE:$CI_COMMIT_TAG .
|
|
- docker push $CI_REGISTRY_IMAGE:$CI_COMMIT_TAG
|
|
only:
|
|
- tags
|