You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

16 lines
619 B

  1. ---
  2. pipeline image:
  3. stage: build
  4. image: docker:20.10.22-cli
  5. variables:
  6. DOCKER_TLS_CERTDIR: ""
  7. services:
  8. - name: docker:20.10.22-dind
  9. # See https://gitlab.com/gitlab-org/gitlab-runner/-/issues/27300 for why this is required
  10. command: ["--tls=false"]
  11. before_script:
  12. - echo $CI_REGISTRY_PASSWORD | docker login -u $CI_REGISTRY_USER --password-stdin $CI_REGISTRY
  13. script:
  14. # DOCKER_HOST is overwritten if we set it as a GitLab variable
  15. - DOCKER_HOST=tcp://docker:2375; docker build --network host --file pipeline.Dockerfile --tag $PIPELINE_IMAGE .
  16. - docker push $PIPELINE_IMAGE