Commit dff32570 authored by Mathieu Giraud's avatar Mathieu Giraud

Merge branch 'feature/3551-docker_tag_date' into 'dev'

.gitlab-ci.yml docker tag reverse date and sha1

See merge request !326
parents 4b6eac6a ab49876d
Pipeline #44138 passed with stages
in 6 minutes and 6 seconds
......@@ -343,7 +343,7 @@ deploy_docker:
script:
- export CUR_DATE=date +%Y-%m-%d
- export TYPE=$CI_COMMIT_REF_NAME | awk '{ gsub(/prod-/, "") }{ print $1 }'
- export TAG="vidjil/$TYPE:$CI_COMMIT_SHA-$CUR_DATE"
- export TAG="vidjil/$TYPE:$CUR_DATE-$CI_COMMIT_SHA"
- docker build --no-cache --build-arg git_branch=$CI_COMMIT_REF_NAME --build-arg build_env=PRODUCTION -t $TAG docker/vidjil-$TYPE
- docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" $CI_REGISTRY
- docker push $TAG
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment