Last modified September 29, 2021

gsctl update cluster

gsctl and the REST API are being phased out. We don't have an end-of-life date yet. However, we recommend to familiarize yourself with our Management API and the kubectl gs plugin as a future-proof replacement.

The gsctl update cluster command allows the modification of some cluster attributes, depending on the workload cluster release version and the provider.

Changing the cluster name is possible on all providers and in all workload cluster release versions.

Cluster labelling is only available for clusters with workload cluster release v10.0.0 and above for AWS, or v13.0.0 and above for Azure. High-availability control planes are available on AWS starting at workload cluster release v11.4.0 .

Usage

The command is called with the cluster ID or name as a positional argument. The desired new name can be specified with the --name or -n flag. The --label flag is used to modify a single label change. It can be specified multiple times in order to change multiple labels at once.

Examples

Modifying the cluster name

gsctl update cluster f01r4 \
  --name "Precious Production Cluster"

Modifying cluster labels

gsctl update cluster vxvc7 \
  --label environment=testing \
  --label locked=

will update the labels of cluster vxvc7. It will add (or update depending on prior existence) label environment=testing and delete the label with key locked.

Switching to high-availability control planes

Starting with workload cluster release v11.4.0 for AWS, a single control plane node cluster can be converted into using multiple control plane nodes in multiple availability zones using a command like the following:

gsctl update cluster vxvc7 \
  --master-ha=true

Note that it is not possible to change from multiple control plane nodes to a single one.

Full argument reference

  • --name or -n: The new cluster name.
  • --label: Specify a single label update. Allowed multiple times. Available on AWS starting at workload cluster release v10.0.0 . To remove a label, set its key to an empty string (labeltodelete=).
  • --master-ha: When set to true, the cluster should be modified to use multiple control plane nodes. Available on AWS starting at workload cluster release v11.4.0 .