|
|
@ -157,11 +157,11 @@ docker:
|
|
|
|
# https://medium.com/devops-with-valentine/how-to-build-a-docker-image-and-push-it-to-the-gitlab-container-registry-from-a-gitlab-ci-pipeline-acac0d1f26df
|
|
|
|
# https://medium.com/devops-with-valentine/how-to-build-a-docker-image-and-push-it-to-the-gitlab-container-registry-from-a-gitlab-ci-pipeline-acac0d1f26df
|
|
|
|
script:
|
|
|
|
script:
|
|
|
|
- echo $CI_REGISTRY_PASSWORD | docker login -u $CI_REGISTRY_USER $CI_REGISTRY --password-stdin
|
|
|
|
- echo $CI_REGISTRY_PASSWORD | docker login -u $CI_REGISTRY_USER $CI_REGISTRY --password-stdin
|
|
|
|
- docker build -t $CI_REGISTRY_IMAGE .
|
|
|
|
- docker build -t $CI_REGISTRY_IMAGE:$CI_COMMIT_TAG .
|
|
|
|
- docker push $CI_REGISTRY_IMAGE
|
|
|
|
- docker push $CI_REGISTRY_IMAGE:$CI_COMMIT_TAG
|
|
|
|
only:
|
|
|
|
rules:
|
|
|
|
variables:
|
|
|
|
- if: $CI_COMMIT_TAG
|
|
|
|
- $CI_DEFAULT_BRANCH == $CI_COMMIT_REF_NAME
|
|
|
|
interruptible: false
|
|
|
|
|
|
|
|
|
|
|
|
release:
|
|
|
|
release:
|
|
|
|
stage: release
|
|
|
|
stage: release
|
|
|
|