Skip to content
Snippets Groups Projects
Commit 438da5d5 authored by ale's avatar ale
Browse files

Fix Docker build stage

parent c9d24553
No related branches found
No related tags found
No related merge requests found
...@@ -6,17 +6,17 @@ stages: ...@@ -6,17 +6,17 @@ stages:
docker_ci_image: docker_ci_image:
variables: variables:
IMAGE_TAG: $CI_REGISTRY_NAME:$CI_COMMIT_REF_SLUG IMAGE_TAG: $CI_REGISTRY_IMAGE:$CI_COMMIT_REF_SLUG
stage: build stage: build
image: ${CI_DEPENDENCY_PROXY_GROUP_IMAGE_PREFIX}/docker:stable image: ${CI_DEPENDENCY_PROXY_GROUP_IMAGE_PREFIX}/docker:stable
services: services:
- name: ${CI_DEPENDENCY_PROXY_GROUP_IMAGE_PREFIX}/docker:dind - name: ${CI_DEPENDENCY_PROXY_GROUP_IMAGE_PREFIX}/docker:dind
alias: docker alias: docker
script: script:
- echo -n "$CI_JOB_TOKEN" | docker login -u gitlab-ci-token --password-stdin $CI_REGISTRY_NAME - echo -n "$CI_JOB_TOKEN" | docker login -u gitlab-ci-token --password-stdin registry.git.autistici.org
- cd ci && docker build -build-arg ci_token=$CI_JOB_TOKEN --pull -t $IMAGE_TAG . - cd ci && docker build -build-arg ci_token=$CI_JOB_TOKEN --pull -t $IMAGE_TAG .
- docker tag $IMAGE_TAG $CI_REGISTRY_NAME:runner - docker tag $IMAGE_TAG $CI_REGISTRY_IMAGE:runner
- docker push $CI_REGISTRY_NAME:runner - docker push $CI_REGISTRY_IMAGE:runner
only: only:
changes: changes:
- ci/** - ci/**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment