Documentation
¶
Index ¶
- func BuildClientCmd(kubeconfig, context string, ...) clientcmd.ClientConfig
- func BuildClientConfig(kubeconfig, context string) (*rest.Config, error)
- func DefaultRestConfig(kubeconfig, configContext string, fns ...func(config *rest.Config)) (*rest.Config, error)
- func NewClientConfigForRestConfig(restConfig *rest.Config) clientcmd.ClientConfig
- func SetRestDefaults(config *rest.Config) *rest.Config
- func WaitForCacheSync(name string, stop <-chan struct{}, cacheSyncs ...cache.InformerSynced) (r bool)
- type CLIClient
- type Client
- type ClientOption
- type PartialFactory
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuildClientCmd ¶
func BuildClientCmd(kubeconfig, context string, overrides ...func(configOverrides *clientcmd.ConfigOverrides)) clientcmd.ClientConfig
func DefaultRestConfig ¶
func NewClientConfigForRestConfig ¶
func NewClientConfigForRestConfig(restConfig *rest.Config) clientcmd.ClientConfig
NewClientConfigForRestConfig creates a new k8s clientcmd.ClientConfig from the given rest.Config.
func WaitForCacheSync ¶ added in v0.2.4
func WaitForCacheSync(name string, stop <-chan struct{}, cacheSyncs ...cache.InformerSynced) (r bool)
Types ¶
type CLIClient ¶
type CLIClient interface {
Client
DynamicClientFor(gvk schema.GroupVersionKind, obj *unstructured.Unstructured, namespace string) (dynamic.ResourceInterface, error)
}
func NewCLIClient ¶
func NewCLIClient(clientCfg clientcmd.ClientConfig, opts ...ClientOption) (CLIClient, error)
type Client ¶
type Client interface {
RESTConfig() *rest.Config
Ext() kubeExtClient.Interface
Kube() kubernetes.Interface
Dynamic() dynamic.Interface
Metadata() metadata.Interface
Informers() informerfactory.InformerFactory
ClusterID() cluster.ID
}
type ClientOption ¶
func WithCluster ¶ added in v0.2.4
func WithCluster(id cluster.ID) ClientOption
func WithRevision ¶
func WithRevision(revision string) ClientOption
type PartialFactory ¶ added in v0.2.4
type PartialFactory interface {
// DynamicClient returns a dynamic client ready for use
DynamicClient() (dynamic.Interface, error)
// KubernetesClientSet gives you back an external clientset
KubernetesClientSet() (*kubernetes.Clientset, error)
// Returns a RESTClient for accessing Kubernetes resources or an error.
RESTClient() (*rest.RESTClient, error)
// contains filtered or unexported methods
}
Click to show internal directories.
Click to hide internal directories.