diff --git a/shell/mirror_tkg_containers.sh b/shell/mirror_tkg_containers.sh index cdb6600..3cb6270 100755 --- a/shell/mirror_tkg_containers.sh +++ b/shell/mirror_tkg_containers.sh @@ -10,6 +10,7 @@ if [ ! -e ${TKG_CLI_PATH} ]; then fi LIST=( +registry.tkg.vmware.run/kind/node:v1.17.3_vmware.2 registry.tkg.vmware.run/cluster-api/cluster-api-aws-controller:v0.5.2_vmware.1 registry.tkg.vmware.run/cluster-api/kubeadm-control-plane-controller:v0.3.3_vmware.1 registry.tkg.vmware.run/cluster-api/kubeadm-bootstrap-controller:v0.3.3_vmware.1 @@ -46,10 +47,14 @@ do imageDestination=$(echo -n "$image" | sed "s/$origImageRepo/$newImageRepo/g") echo "> Pulling $image" docker pull "$image" - echo "> Pushing $imageDestination" - docker tag "$image" "$imageDestination" - docker push "$imageDestination" - docker rmi "$image" + # Do not push KIND container into Harbor as this is only used locally + if [ "$image" != "registry.tkg.vmware.run/kind/node:v1.17.3_vmware.2" ]; then + echo "> Tagging $image -> $imageDestination" + docker tag "$image" "$imageDestination" + echo "> Pushing $imageDestination" + docker push "$imageDestination" + docker rmi "$image" + fi # Leaving these containers cached in Photon to speed up KIND deployment if [[ "$imageDestination" != "${REGISTRY_URL}/library/cert-manager/cert-manager-webhook:v0.11.0_vmware.1" ]] && [[ "$imageDestination" != "${REGISTRY_URL}/library/cert-manager/cert-manager-cainjector:v0.11.0_vmware.1" ]] && [[ "$imageDestination" != "${REGISTRY_URL}/library/cert-manager/cert-manager-controller:v0.11.0_vmware.1" ]]; then docker rmi "$imageDestination"