Documentation ¶
Overview ¶
Package k8s contains utilities for Antrea interactions with Kubernetes.
Index ¶
- func CreateClients(config componentbaseconfig.ClientConnectionConfiguration, ...) (clientset.Interface, aggregatorclientset.Interface, crdclientset.Interface, ...)
- func CreateLegacyCRDClient(config componentbaseconfig.ClientConnectionConfiguration, ...) (legacycrdclientset.Interface, error)
- func CreateNetworkAttachDefClient(config componentbaseconfig.ClientConnectionConfiguration, ...) (netdefclient.K8sCniCncfIoV1Interface, error)
- func GetNodeAddrs(node *v1.Node) (*ip.DualStackIPs, error)
- func NamespacedName(namespace, name string) string
- func ParseStatefulSetName(name string) (statefulSetName string, index int, err error)
- func SplitNamespacedName(name string) (string, string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateClients ¶
func CreateClients(config componentbaseconfig.ClientConnectionConfiguration, kubeAPIServerOverride string) ( clientset.Interface, aggregatorclientset.Interface, crdclientset.Interface, apiextensionclientset.Interface, error)
CreateClients creates kube clients from the given config.
func CreateLegacyCRDClient ¶
func CreateLegacyCRDClient(config componentbaseconfig.ClientConnectionConfiguration, kubeAPIServerOverride string) (legacycrdclientset.Interface, error)
CreateLegacyCRDClient creates legacyCRD client from the given config.
func CreateNetworkAttachDefClient ¶ added in v1.5.0
func CreateNetworkAttachDefClient(config componentbaseconfig.ClientConnectionConfiguration, kubeAPIServerOverride string) (netdefclient.K8sCniCncfIoV1Interface, error)
CreateNetworkAttachDefClient creates net-attach-def client handle from the given config.
func GetNodeAddrs ¶ added in v1.3.0
func GetNodeAddrs(node *v1.Node) (*ip.DualStackIPs, error)
GetNodeAddrs gets the available IP addresses of a Node. GetNodeAddrs will first try to get the NodeInternalIP, then try to get the NodeExternalIP. If no error is returned, the returned DualStackIPs includes at least one IPv4 or IPv6 address.
func NamespacedName ¶
NamespacedName generates the conventional K8s resource name, which connects namespace and name with "/".
func ParseStatefulSetName ¶ added in v1.5.0
func SplitNamespacedName ¶ added in v1.5.0
SplitNamespacedName splits conventional K8s resource name to Namespace and Resource Name
Types ¶
This section is empty.