From 5f3a4df766ab7d18736faf340f974832dfaa8202 Mon Sep 17 00:00:00 2001 From: Anton Dutov Date: Thu, 18 Nov 2021 10:40:54 +0300 Subject: [PATCH] Upgrade kaniko version && force flag --- Dockerfile | 7 ++++++- plugin.sh | 3 ++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 7579cd5..13bf5b5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,11 +1,16 @@ -FROM gcr.io/kaniko-project/executor:debug-v0.19.0 +FROM busybox +FROM gcr.io/kaniko-project/executor:v1.7.0 +ENV PATH /bin ENV HOME /root ENV USER root ENV SSL_CERT_DIR=/kaniko/ssl/certs ENV DOCKER_CONFIG /kaniko/.docker/ ENV DOCKER_CREDENTIAL_GCR_CONFIG /kaniko/.config/gcloud/docker_credential_gcr_config.json +COPY --from=busybox / / + # add the wrapper which acts as a drone plugin COPY plugin.sh /kaniko/plugin.sh + ENTRYPOINT [ "/kaniko/plugin.sh" ] diff --git a/plugin.sh b/plugin.sh index 31e8cd3..da2e845 100755 --- a/plugin.sh +++ b/plugin.sh @@ -1,4 +1,4 @@ -#!/busybox/sh +#!/bin/sh set -euo pipefail @@ -99,6 +99,7 @@ fi /kaniko/executor -v ${LOG} \ --context=${CONTEXT} \ --dockerfile=${DOCKERFILE} \ + --force \ ${EXTRA_OPTS} \ ${DESTINATIONS} \ ${CACHE:-} \