Documentation ¶
Index ¶
- Constants
- func DeleteContext(config *clientcmdapi.Config, cpName string) error
- func IsHostingClusterContextPreferenceSet(config *clientcmdapi.Config) bool
- func LoadAndMerge(ctx context.Context, client kubernetes.Clientset, ...) error
- func LoadAndMergeNoWrite(ctx context.Context, client kubernetes.Clientset, ...) error
- func LoadKubeconfig(ctx context.Context) (*clientcmdapi.Config, error)
- func SaveHostingClusterContextPreference(ctx context.Context) error
- func SetHostingClusterContextPreference(config *clientcmdapi.Config, userSuppliedContext *string)
- func SwitchContext(config *clientcmdapi.Config, cpName string) error
- func SwitchToHostingClusterContext(config *clientcmdapi.Config, removeExtension bool) error
- func WatchForSecretCreation(clientset kubernetes.Clientset, controlPlaneName, secretName string) error
- func WriteKubeconfig(ctx context.Context, config *clientcmdapi.Config) error
Constants ¶
View Source
const ( ConfigExtensionName = "kflex-config-extension-name" InitialContextName = "kflex-initial-ctx-name" )
Variables ¶
This section is empty.
Functions ¶
func DeleteContext ¶
func DeleteContext(config *clientcmdapi.Config, cpName string) error
func IsHostingClusterContextPreferenceSet ¶ added in v0.6.2
func IsHostingClusterContextPreferenceSet(config *clientcmdapi.Config) bool
func LoadAndMerge ¶
func LoadAndMergeNoWrite ¶ added in v0.2.5
func LoadAndMergeNoWrite(ctx context.Context, client kubernetes.Clientset, name, controlPlaneType string, konfig *clientcmdapi.Config) error
LoadAndMergeNoWrite: works as LoadAndMerge but on supplied konfig from file and does not write it back
func LoadKubeconfig ¶
func LoadKubeconfig(ctx context.Context) (*clientcmdapi.Config, error)
func SaveHostingClusterContextPreference ¶ added in v0.6.2
func SetHostingClusterContextPreference ¶ added in v0.6.2
func SetHostingClusterContextPreference(config *clientcmdapi.Config, userSuppliedContext *string)
sets hosting cluster context to current context if userSuppliedContext is nil, otherwise set to userSuppliedContext
func SwitchContext ¶
func SwitchContext(config *clientcmdapi.Config, cpName string) error
func SwitchToHostingClusterContext ¶ added in v0.6.2
func SwitchToHostingClusterContext(config *clientcmdapi.Config, removeExtension bool) error
func WatchForSecretCreation ¶
func WatchForSecretCreation(clientset kubernetes.Clientset, controlPlaneName, secretName string) error
func WriteKubeconfig ¶
func WriteKubeconfig(ctx context.Context, config *clientcmdapi.Config) error
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.