Last modified October 2, 2020
kubectl gs get clusters
kgsset up for the command
Like with all
get commands in
kubectl, this command can be used to get details on one item, a cluster in this case, or list several of them.
Get a list of clusters
kgs get clusters
to list some information on all clusters available to you in the current installation.
Here is some example output:
ID CREATED CONDITION RELEASE ORGANIZATION DESCRIPTION 3i99p 2020-09-29 11:51:52 +0000 UTC CREATED 12.1.4 giantswarm ced0ps kong pm
Get specific cluster
When used with a cluster ID as additional argument, the command will show details for a single cluster. Example:
kgs get clusters ab12c
Note: As an alternative to
get cluster will also work.
The standard tabular output format features these columns:
ID: Unique identifier of the cluster.
CREATED: Date and time of the Cluster CR creation.
CONDITION: Latest condition reported for the cluster. Either of:
CREATING: The cluster is currently being created.
CREATED: Cluster creation is finished.
UPDATING: The cluster is currently being updated, e. g. during an upgrade.
UPDATED: The cluster update is finished.
DELETING: The cluster is being deleted.
RELEASE: Tenant cluster release version of the cluster.
ORGANIZATION: Organization owning the cluster.
DESCRIPTION: User friendly description for the cluster.
Here we document the flags that have a particular meaning for the
get clusters command. Use
kgs get clusters --help for a full list.
kubectl commonly allows to specify the output format for all
kgs get clusters is no different.
To inspect a cluster’s main custom resource in YAML notation, add the
--output yaml flag (or
-o yaml in short) to the command.
kgs get clusters ab12c --output yaml
When applied without a cluster ID argument, the output will be a list of resources. Example:
$ kgs get clusters ab12c --output yaml apiVersion: v1 kind: List items: - apiVersion: infrastructure.giantswarm.io/v1alpha2 kind: AWSCluster ...
kubectl gs login- Ensure an authenticated kubectl context.