When attempting to deploy a new Tanzu Management Cluster it fails at the following step:
Writing configurationStarting control-planeInstalling CNIInstalling StorageClassWaiting 2m0s for control-plane = ReadyReady after 26sBootstrapper created. Kubeconfig: /root/.kube-tkg/tmp/config_###### -----> Temporary kube config path
Kapp-controller configuration file: /tmp/###########waiting for resource kapp-controller of type *v1.Deployment to be up and runningpods are not yet running for deployment 'kapp-controller' in namespace 'tkg-system', retrying
2.x
export /root/.kube-tkg/tmp/config_####### ---> kubeconfig path from the deployment failure error
kubectl describe pod -n tkg-system -l app=kapp-controller showed that the temporary cluster was unable to pull the image from the harbor registry due to certificate errorWarning###############": failed to pull and unpack image "#############/tkg/packages/core/kapp-controller@sha#################": failed to resolve reference "#############/tkg/packages/core/kapp-controller@sha#################": failed to do request: Head "https://<harbor fqdn>/v2/tkg/packages/core/kapp-controller/manifests/sha256:######################": tls: failed to verify certificate: x509: certificate signed by unknown authority
cat /path/to/your/ca.crt | base64 -w 0.config/tanzu/tkg/config.yaml or the specific configuration file passed with -f during deployment. TKG_CUSTOM_IMAGE_REPOSITORY_CA_CERTIFICATE:"<base 64 format of the certificate>".Kind get clusterskind delete cluster --name <Cluster name>TKG_CUSTOM_IMAGE_REPOSITORY_SKIP_TLS_VERIFY: true
Kind get clusterskind delete cluster --name <Cluster name>Once following either Option A or Option B, retry the deployment again.
If the above options do not resolve the issue, then check the environment variable for the machine where the terminal is open, and include the parameter TKG_CUSTOM_IMAGE_REPOSITORY_CA_CERTIFICATE:"<base 64 format of the certificate>"to include the certificate or include the parameter TKG_CUSTOM_IMAGE_REPOSITORY_SKIP_TLS_VERIFY: true to omit the certificate validation.
Note: The resolution implemented whether (Option A or option B ) to the config.yaml and to the environment variable must be the same.