From 554ce3534ae9e3e7eabeef96f6e9622b64cddc8b Mon Sep 17 00:00:00 2001 From: Myers Carpenter Date: Sun, 6 Jan 2019 21:42:42 -0500 Subject: [PATCH] allow registry to be set --- plugin.sh | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/plugin.sh b/plugin.sh index 9611d22..6fb1f2e 100755 --- a/plugin.sh +++ b/plugin.sh @@ -4,17 +4,21 @@ set -euo pipefail export PATH=$PATH:/kaniko/ -DOCKER_AUTH=`echo -n "${DOCKER_USERNAME}:${DOCKER_PASSWORD}" | base64` +if [[ -n "${PLUGIN_USERNAME}" ]]; then + DOCKER_AUTH=`echo -n "${PLUGIN_USERNAME}:${PLUGIN_PASSWORD}" | base64` -cat > /kaniko/.docker/config.json < /kaniko/.docker/config.json <