Search code examples
configurationkuberneteskopsgoogle-kubernetes-engine

How to load the current Kubernetes cluster configuration with KOPS?


Using KOPS to retrieve the configuration be used with the following:

kops get cluster --name <cluster-name> --output yaml

Then, we have to call the instance groups configuration with the following:

kops get ig --name <cluster-name> --output yaml

Joining the documents require to add the yaml separator ---.

Is there a simpler way to retrieve the current Kubernetes Cluster configuration with KOPS?


Solution

  • According to https://github.com/kubernetes/kops/issues/1758#issuecomment-336604987, the following command will print out the original configuration used to create the cluster:

    kops get -o yaml

    The configuration will include the entire cluster definition!