Documentation
¶
Index ¶
- func AddElevationReasonsToRawKubeconfig(config api.Config, elevationReasons []string) error
- func CreateClusterKubeConfig(clusterID string, kubeConfig api.Config) (string, error)
- func GetElevateContextReasons(config api.Config) []string
- func RemoveClusterKubeConfig(clusterID string) error
- func SaveElevateContextReasons(config api.Config, elevationReason string) ([]string, error)
- func SaveKubeConfig(clusterID string, config api.Config, isMulti bool, kubePath string) error
- func SetKubeConfigBasePath(basePath string) error
- type ElevateContext
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddElevationReasonsToRawKubeconfig ¶ added in v0.1.34
func CreateClusterKubeConfig ¶
CreateClusterKubeConfig creates cluster specific kube config based on a cluster ID
func GetElevateContextReasons ¶ added in v0.1.34
in some cases (mainly when config is created from json) the "ElevateContext Extension" is created as runtime.Unknow object instead of the desired ElevateContext, so we need to Unmarshal the raw definition in that case
func RemoveClusterKubeConfig ¶
RemoveClusterKubeConfig delete cluster specific kube config file
func SaveElevateContextReasons ¶ added in v0.1.34
func SaveKubeConfig ¶
SaveKubeConfig modify Kube config based on user setting
func SetKubeConfigBasePath ¶
Types ¶
type ElevateContext ¶ added in v0.1.34
type ElevateContext struct { Reasons []string `json:"reasons"` LastUsed time.Time `json:"lastUsed"` }
func (*ElevateContext) DeepCopyObject ¶ added in v0.1.34
func (r *ElevateContext) DeepCopyObject() runtime.Object
DeepCopyObject creates a deep copy of the ElevateContext.
func (*ElevateContext) GetObjectKind ¶ added in v0.1.34
func (r *ElevateContext) GetObjectKind() schema.ObjectKind
GetObjectKind returns the schema.GroupVersionKind of the object.
Click to show internal directories.
Click to hide internal directories.