Documentation ¶
Overview ¶
Package kc manage local kubeconfig file
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Delete ¶ added in v0.1.3
func Delete(kubeconfig string)
Delete delete a context from kubeconfig
Types ¶
type AuthInfo ¶
type AuthInfo struct { Name string `json:"name"` User *clientcmdapi.AuthInfo `json:"user"` }
AuthInfo k8sconfig user object
type Cluster ¶
type Cluster struct { Name string `json:"name"` Cluster *clientcmdapi.Cluster `json:"cluster"` }
Cluster k8s cluster object
type Context ¶
type Context struct { Name string `json:"name"` Context *clientcmdapi.Context `json:"context"` }
Context k8s context object
type KubeConfig ¶
type KubeConfig struct { Kind string `json:"kind,omitempty"` APIVersion string `json:"apiVersion,omitempty"` Clusters []Cluster `json:"clusters"` AuthInfos []AuthInfo `json:"users"` Contexts []Context `json:"contexts"` CurrentContext string `json:"current-context"` }
KubeConfig kubeconfig object
Click to show internal directories.
Click to hide internal directories.