This topic provides general information about deploying and managing workload clusters.
In VMware Tanzu Kubernetes Grid, workload clusters are the Kubernetes clusters in which your application workloads run.
Tanzu Kubernetes Grid automatically deploys clusters to the platform on which you deployed the management cluster. For example, you cannot deploy clusters to Amazon Web Services (AWS) or Azure from a management cluster that is running in vSphere, or the reverse. It is not possible to use shared services between the different providers because, for example, vSphere clusters are reliant on sharing vSphere networks and storage, while AWS and Azure use their own systems. Tanzu Kubernetes Grid automatically deploys clusters from whichever management cluster you have set as the context for the CLI by using the
tanzu login command. For information about
tanzu login, see Manage Your Management Clusters.
For information about how to upgrade existing clusters to a new version of Kubernetes, see Upgrade Workload Clusters.
When you create a management cluster, the Tanzu CLI and
kubectl contexts are automatically set to that management cluster. However, Tanzu Kubernetes Grid does not automatically set the
kubectl context to a workload cluster when you create it. You must set the
kubectl context to a workload cluster manually by using the
kubectl config use-context command.
By default, unless you specify the
KUBECONFIG option to save the
kubeconfig for a cluster to a specific file, all workload clusters that you deploy are added to a shared
.kube/config file. If you delete the shared
.kube/config file and you still have the
.kube-tkg/config file for the management cluster, you can recover the
.kube/config of the workload clusters with the
tanzu cluster kubeconfig get <my-cluster> command.
Do not change context or edit the
.kube/config files while Tanzu Kubernetes Grid operations are running.
If you have vSphere 7 and you have enabled the vSphere with Tanzu feature, you can use the Tanzu CLI to interact with the vSphere with Tanzu Supervisor Cluster, to deploy workload clusters in vSphere with Tanzu. For more information, see Add a vSphere with Tanzu Supervisor Cluster as a Management Cluster.
You can use the Tanzu CLI to create cluster manifest files for workload clusters without actually creating the clusters. To generate a cluster manifest YAML file that you can pass to
kubectl apply -f, run the
tanzu cluster create command with the
--dry-run option and save the output to a file. Use the same options and configuration
--file that you would use if you were creating the cluster, for example:
tanzu cluster create my-cluster --file my-cluster-config.yaml --dry-run > my-cluster-manifest.yaml
You can then use
kubectl to deploy the cluster from the manifest as described in Deploy a Cluster from a Saved Manifest File.
You configure proxies, Machine Health Check, private registries, and Antrea on Workload Clusters in the same way as you do for management clusters. For information, see Create a Management Cluster Configuration File.