message: CI: use kaniko to build image
diff: @@ -13,15 +13,13 @@ variables:
  .prepare:docker: &prepare_docker
  stage: prepare
  image:
  - name: docker
  - before_script:
  - - docker version
  - - docker login --username "${CI_REGISTRY_USER}" --password "${CI_REGISTRY_PASSWORD}" "${CI_REGISTRY}"
  + name: gcr.io/kaniko-project/executor:debug
  + entrypoint: [ "" ]
  script:
  - - docker build -f ${DOCKER_FILE} -t ${DOCKER_IMAGE}:${DOCKER_TAG} .
  - - docker push ${DOCKER_IMAGE}:${DOCKER_TAG}
  - tags:
  - - docker
  + - mkdir -p /kaniko/.docker
  + - echo "{\"auths\":{\"${CI_REGISTRY}\":{\"username\":\"${CI_REGISTRY_USER}\",\"password\":\"${CI_REGISTRY_PASSWORD}\"}}}" > /kaniko/.docker/config.json
  + - /kaniko/executor --context ${CI_PROJECT_DIR} --dockerfile ${CI_PROJECT_DIR}/${DOCKER_FILE} --destination ${DOCKER_IMAGE}:${DOCKER_TAG} --snapshotMode=redo --single-snapshot
  +
  prepare:docker:
  <<: *prepare_docker
  