Documentation ¶
Index ¶
- func AreLabelsContained(needle map[string]string, haystack map[string]string) bool
- func BuildObjectKey(obj *pcn_types.ObjectQuery, peerType string) string
- func BuildQuery(name string, labels map[string]string) *pcn_types.ObjectQuery
- func GetPodVirtualIP(ip string) string
- func ImplodeLabels(labels map[string]string, sep string, sortKeys bool) string
- func SetVPodsRange(vrange *net.IPNet)
- type HostNetworkConf
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AreLabelsContained ¶
AreLabelsContained checks if the labels in the first argument are present in the second one and values are the same. Basically checks if a map is a sub-map.
func BuildObjectKey ¶
func BuildObjectKey(obj *pcn_types.ObjectQuery, peerType string) string
BuildObjectKey builds the key of an object based on its query
func BuildQuery ¶
func BuildQuery(name string, labels map[string]string) *pcn_types.ObjectQuery
BuildQuery builds a query to be sent to a controller
func GetPodVirtualIP ¶
GetPodVirtualIP gets a pod's virtual IP starting from the IP assigned to it
func ImplodeLabels ¶
ImplodeLabels set labels in a key1=value1,key2=value2 format Values are separated by sep and the third value specifies if keys should be sorted.
func SetVPodsRange ¶
Types ¶
type HostNetworkConf ¶
Describes the network configuration of the host
func GetHostNetworkConf ¶
func GetHostNetworkConf(NodeIP string) (conf HostNetworkConf, err error)
TODO: Improve, it should be used together with the k8s node api
Click to show internal directories.
Click to hide internal directories.