This is a known issue affecting TKG 1.3.x after upgrading from TKG 1.2.x. There is currently no resolution. Workaround:
Register the CNI add-on:
- Create a directory for taking the overlay files backup by issuing the following command:
mkdir ~/.tanzu/addon_overlay_backup
- Take a backup of the file ~/.tanzu/tkg/providers/ytt/02_addons/cni/add_cni.yaml file by issuing the following command:
cp ~/.tanzu/tkg/providers/ytt/02_addons/cni/add_cni.yaml ~/.tanzu/addon_overlay_backup
- Open the ~/.tanzu/tkg/providers/ytt/02_addons/cni/add_cni.yaml file with a text editor.
- Find the following line:
#@ if data.values.PROVIDER_TYPE != "tkg-service-vsphere" and not data.values.FILTER_BY_ADDON_TYPE:
and replace it with
#@ if data.values.PROVIDER_TYPE != "tkg-service-vsphere":
- Save and close the file.
- Follow the steps noted in Register Core Add-ons to complete the registration of the CNI add-on.
Note: This process is needed for the management and workload clusters.
Register the CPI add-on:
- Take a backup of the ~/.tanzu/tkg/providers/ytt/02_addons/cpi/cpi_secret_crs.yaml file by issuing the following command:
cp ~/.tanzu/tkg/providers/ytt/02_addons/cpi/cpi_secret_crs.yaml ~/.tanzu/addon_overlay_backup
- Open the ~/.tanzu/tkg/providers/ytt/02_addons/cpi/cpi_secret_crs.yaml file with a text editor.
- Find the following line
#@ if data.values.PROVIDER_TYPE == "vsphere" and data.values.TKG_CLUSTER_ROLE != "workload" and not data.values.FILTER_BY_ADDON_TYPE:
and replace it with
#@ if data.values.PROVIDER_TYPE == "vsphere" and data.values.TKG_CLUSTER_ROLE != "workload":
- Save and close the file.
- Follow the steps noted in Register Core Add-ons to complete the registration of the CPI add-on.
Note: This process is only needed for the management cluster.
Important Note: Once the CNI and CPI add-ons are registered for the management and workload clusters, make sure to revert the overlay files from the backup location taken in the very first step for each add-on type.