Skip to content

Commit

Permalink
disable internal registry (harbor) on openshift builds
Browse files Browse the repository at this point in the history
  • Loading branch information
twardnw committed Nov 3, 2020
1 parent 0633f0a commit 42477bc
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions images/oc-build-deploy-dind/build-deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,11 @@ DOCKER_REGISTRY_TOKEN=$(cat /var/run/secrets/kubernetes.io/serviceaccount/token)
docker login -u=jenkins -p="${DOCKER_REGISTRY_TOKEN}" ${OPENSHIFT_REGISTRY}

INTERNAL_REGISTRY_LOGGED_IN="false"
if [ ! -z ${INTERNAL_REGISTRY_URL} ] && [ ! -z ${INTERNAL_REGISTRY_USERNAME} ] && [ ! -z ${INTERNAL_REGISTRY_PASSWORD} ] ; then
if echo "docker login -u '${INTERNAL_REGISTRY_USERNAME}' -p '${INTERNAL_REGISTRY_PASSWORD}' ${INTERNAL_REGISTRY_URL}" | /bin/bash; then
INTERNAL_REGISTRY_LOGGED_IN="true"
fi
fi
# if [ ! -z ${INTERNAL_REGISTRY_URL} ] && [ ! -z ${INTERNAL_REGISTRY_USERNAME} ] && [ ! -z ${INTERNAL_REGISTRY_PASSWORD} ] ; then
# if echo "docker login -u '${INTERNAL_REGISTRY_USERNAME}' -p '${INTERNAL_REGISTRY_PASSWORD}' ${INTERNAL_REGISTRY_URL}" | /bin/bash; then
# INTERNAL_REGISTRY_LOGGED_IN="true"
# fi
# fi

DEPLOYER_TOKEN=$(cat /var/run/secrets/lagoon/deployer/token)

Expand Down

0 comments on commit 42477bc

Please sign in to comment.