Documentation ¶
Index ¶
- Constants
- func IPPoolToThirdParty(kvp *model.KVPair) *thirdparty.IpPool
- func K8sErrorToCalico(ke error, id interface{}) error
- func K8sNodeToCalico(node *kapiv1.Node) (*model.KVPair, error)
- func NewIPPools(c *kubernetes.Clientset, r *rest.RESTClient) api.Client
- func NewNodeClient(c *kubernetes.Clientset, r *rest.RESTClient) api.Client
- func NewSystemNetworkPolicies(c *kubernetes.Clientset, r *rest.RESTClient) api.Client
- func SystemNetworkPolicyToThirdParty(kvp *model.KVPair) *thirdparty.SystemNetworkPolicy
- func ThirdPartyToIPPool(t *thirdparty.IpPool) *model.KVPair
- func ThirdPartyToSystemNetworkPolicy(t *thirdparty.SystemNetworkPolicy) *model.KVPair
Constants ¶
const ( SystemNetworkPolicyResourceName = "systemnetworkpolicies" SystemNetworkPolicyTPRName = "system-network-policy.projectcalico.org" SystemNetworkPolicyNamePrefix = "snp.projectcalico.org/" )
Variables ¶
This section is empty.
Functions ¶
func IPPoolToThirdParty ¶
func IPPoolToThirdParty(kvp *model.KVPair) *thirdparty.IpPool
IPPoolToThirdParty takes a Calico IP Pool and returns the equivalent ThirdPartyResource representation.
func K8sErrorToCalico ¶
K8sErrorToCalico returns the equivalent libcalico error for the given kubernetes error.
func K8sNodeToCalico ¶ added in v1.2.0
K8sNodeToCalico converts a Kubernetes format node, with Calico annotations, to a Calico Node.
func NewIPPools ¶
func NewIPPools(c *kubernetes.Clientset, r *rest.RESTClient) api.Client
func NewNodeClient ¶ added in v1.2.0
func NewNodeClient(c *kubernetes.Clientset, r *rest.RESTClient) api.Client
func NewSystemNetworkPolicies ¶ added in v1.3.0
func NewSystemNetworkPolicies(c *kubernetes.Clientset, r *rest.RESTClient) api.Client
func SystemNetworkPolicyToThirdParty ¶ added in v1.3.0
func SystemNetworkPolicyToThirdParty(kvp *model.KVPair) *thirdparty.SystemNetworkPolicy
SystemNetworkPolicyToThirdParty takes a Calico Policy and returns the equivalent ThirdPartyResource representation.
func ThirdPartyToIPPool ¶
func ThirdPartyToIPPool(t *thirdparty.IpPool) *model.KVPair
ThirdPartyToIPPool takes a Kubernetes ThirdPartyResource representation of a Calico IP Pool and returns the equivalent IPPool object.
func ThirdPartyToSystemNetworkPolicy ¶ added in v1.3.0
func ThirdPartyToSystemNetworkPolicy(t *thirdparty.SystemNetworkPolicy) *model.KVPair
ThirdPartyToSystemNetworkPolicy takes a Kubernetes ThirdPartyResource representation of a Calico Policy and returns the equivalent SystemNetworkPolicy object.
Types ¶
This section is empty.