1.container_job_template: 2 extends: .base_job_template 3 image: docker:stable 4 stage: containers 5 services: 6 - docker:dind 7 before_script: 8 - export TAG="$CI_REGISTRY_IMAGE/qemu/$NAME:latest" 9 - export COMMON_TAG="$CI_REGISTRY/qemu-project/qemu/$NAME:latest" 10 - apk add python3 11 - docker info 12 - docker login $CI_REGISTRY -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" 13 script: 14 - echo "TAG:$TAG" 15 - echo "COMMON_TAG:$COMMON_TAG" 16 - ./tests/docker/docker.py --engine docker build 17 -t "qemu/$NAME" -f "tests/docker/dockerfiles/$NAME.docker" 18 -r $CI_REGISTRY/qemu-project/qemu 19 - docker tag "qemu/$NAME" "$TAG" 20 - docker push "$TAG" 21 after_script: 22 - docker logout 23