Skip to content
Snippets Groups Projects
Commit ab56f521 authored by Éloïs's avatar Éloïs
Browse files

Update .gitlab-ci.yml

parent 09672cdd
No related branches found
No related tags found
No related merge requests found
Pipeline #6308 canceled
image: docker:19.03
variables:
DOCKER_TLS_CERTDIR: "/certs"
DOCKER_DRIVER: overlay2
image: docker:18.06
services:
- docker:19.03-dind
- docker:18.06-dind
before_script:
- docker info
......@@ -13,8 +9,6 @@ before_script:
test_build_image:
tags:
- dunitrust
services:
- docker:dind
script:
- docker build .
except:
......@@ -23,12 +17,13 @@ test_build_image:
build_image:
tags:
- dunitrust
services:
- docker:dind
script:
- docker pull "$CI_REGISTRY_IMAGE:latest" || true
- docker build --cache-from "$CI_REGISTRY_IMAGE:latest" --pull -t "$CI_REGISTRY_IMAGE:$CI_BUILD_TAG" .
- docker login -u "gitlab-ci-token" -p "$CI_BUILD_TOKEN" $CI_REGISTRY
- docker build --pull -t "$CI_REGISTRY_IMAGE:$CI_BUILD_TAG" .
- docker login -u "gitlab-ci-token" -p "$CI_BUILD_TOKEN" $CI_REGISTRY
- docker tag $CI_REGISTRY_IMAGE:$CI_BUILD_TAG $CI_REGISTRY_IMAGE:latest
- docker push "$CI_REGISTRY_IMAGE:$CI_BUILD_TAG"
- docker push "$CI_REGISTRY_IMAGE:latest"
only:
- tags
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment