package
Version:
v0.0.0-...-5c47c4c
Opens a new window with list of versions in this module.
Published: Apr 4, 2024
License: EPL-2.0
Opens a new window with license information.
Imports: 9
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
CreateKubeConfig creates a kubeconfig located at $KUBECONFIG if set.
If it is not set then fall back to $HOME/.kube/config
type ClusterInfo struct {
CertificateAuthority string `yaml:"certificate-authority"`
Server string `yaml:"server"`
}
type Clusters struct {
Cluster ClusterInfo `yaml:"cluster"`
Name string `yaml:"name"`
}
type Context struct {
Cluster string `yaml:"cluster"`
Namespace string `yaml:"namespace"`
User string `yaml:"user"`
}
type Contexts struct {
Context Context `yaml:"context"`
Name string `yaml:"name"`
}
type KubeConfig struct {
APIVersion string `yaml:"apiVersion"`
Clusters []Clusters `yaml:"clusters"`
Users []Users `yaml:"users"`
Contexts []Contexts `yaml:"contexts"`
CurrentContext string `yaml:"current-context"`
Kind string `yaml:"kind"`
}
type User struct {
Token string `yaml:"token"`
}
type Users struct {
Name string `yaml:"name"`
User User `yaml:"user"`
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.