fwdcfg

package
v1.22.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 19, 2022 License: Apache-2.0 Imports: 4 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ConfigGetter added in v1.13.1

type ConfigGetter struct {
	ConfigFlag *genericclioptions.ConfigFlags
}

ConfigGetter

func NewConfigGetter added in v1.13.1

func NewConfigGetter() *ConfigGetter

NewConfigGetter

func (*ConfigGetter) GetClientConfig added in v1.13.1

func (c *ConfigGetter) GetClientConfig(cfgFilePath string) (*clientcmdapi.Config, error)

GetClientConfig build the ClientConfig and return rawConfig if cfgFilePath is set special, use it. otherwise search the KUBECONFIG environment variable and merge it. if KUBECONFIG env is blank, use the default kubeconfig in $HOME/.kube/config

func (*ConfigGetter) GetRESTClient added in v1.13.1

func (c *ConfigGetter) GetRESTClient() (*restclient.RESTClient, error)

GetRestClient return the RESTClient

func (*ConfigGetter) GetRestConfig added in v1.13.1

func (c *ConfigGetter) GetRestConfig(cfgFilePath string, context string) (*restclient.Config, error)

GetRestConfig uses the kubectl config file to connect to a cluster.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL