This article provides steps to create a TKG workload cluster using a custom-created configuration file. It is recommended to use a separate configuration file for the creation of each workload cluster.
Your are not able to create a Tanzu Kubernetes Grid (TKG) workload cluster after the upgrade of the management cluster from v1.2.1 to v1.3.0.
After the upgrade of the management cluster from v1.2.1 to v1.3.0, the Tanzu CLI is unable to locate the configuration file for the management cluster under the default location, ~/.tanzu/tkg/clusterconfigs/or
~/.tanzu/tkg/cluster-config.yaml.
This is a known issue with TKG 1.3 and currently, there is no resolution. However, there is a workaround available.
To work around this issue, follow these steps:
1. The default cluster configuration file for TKG 1.2.1 is stored at $HOME/.tkg/config.yaml. After the upgrade, this configuration is not migrated to the /home/ubuntu/.tanzu folder. Copy this configuration yaml to ~/.tanzu/tkg/my-workload.yaml which will be used for creating the new workload cluster.
2. Now Make a copy of the management cluster configuration file and save it with a new name.
ubuntu@jumpbox:~/.tkg$ cp config.yaml /home/ubuntu/.tanzu/tkg/my-workload-cluster.yaml
3. Now modify my-workload-cluster.yaml and create the TKG workload cluster with this command:
tanzu cluster create my-workload --file /home/ubuntu/.tanzu/tkg/my-workload-cluster.yaml --plan dev --vsphere-controlplane-endpoint 10.xxx.45.26 -v 9