Loading .gitlab-ci.yml +25 −9 Original line number Diff line number Diff line build with kaniko: stages: - build - push variables: IMAGE_NAME: labs.etsi.org:5050/oop/code/open-exposure-gateway build_image: stage: build tags: - kaniko image: name: gcr.io/kaniko-project/executor:v1.23.2-debug entrypoint: [""] image: docker:latest services: - docker:dind script: - docker build -t $IMAGE_NAME:$CI_COMMIT_SHORT_SHA . - docker tag $IMAGE_NAME:$CI_COMMIT_SHORT_SHA $IMAGE_NAME:latest # conventional project with Dockerfile inside root dir - /kaniko/executor --no-push push_image: stage: push image: docker:latest services: - docker:dind script: - echo "$CI_REGISTRY_PASSWORD" | docker login labs.etsi.org:5050 -u "$CI_REGISTRY_USER" --password-stdin - docker push $IMAGE_NAME:$CI_COMMIT_SHORT_SHA - docker push $IMAGE_NAME:latest only: - main Loading
.gitlab-ci.yml +25 −9 Original line number Diff line number Diff line build with kaniko: stages: - build - push variables: IMAGE_NAME: labs.etsi.org:5050/oop/code/open-exposure-gateway build_image: stage: build tags: - kaniko image: name: gcr.io/kaniko-project/executor:v1.23.2-debug entrypoint: [""] image: docker:latest services: - docker:dind script: - docker build -t $IMAGE_NAME:$CI_COMMIT_SHORT_SHA . - docker tag $IMAGE_NAME:$CI_COMMIT_SHORT_SHA $IMAGE_NAME:latest # conventional project with Dockerfile inside root dir - /kaniko/executor --no-push push_image: stage: push image: docker:latest services: - docker:dind script: - echo "$CI_REGISTRY_PASSWORD" | docker login labs.etsi.org:5050 -u "$CI_REGISTRY_USER" --password-stdin - docker push $IMAGE_NAME:$CI_COMMIT_SHORT_SHA - docker push $IMAGE_NAME:latest only: - main