Documentation ¶
Index ¶
- func AddOrUpdateLabelsOnNode(kubeClient clientset.Interface, labelsToUpdate map[string]string, ...) bool
- func AddOrUpdateTaintOnNode(c clientset.Interface, nodeName string, taints ...*v1.Taint) error
- func AddToNodeAddresses(addresses *[]v1.NodeAddress, addAddresses ...v1.NodeAddress)
- func GetNodeCondition(status *v1.NodeStatus, conditionType v1.NodeConditionType) (int, *v1.NodeCondition)
- func PatchNodeStatus(c v1core.CoreV1Interface, nodeName types.NodeName, oldNode *v1.Node, ...) (*v1.Node, []byte, error)
- func PatchNodeTaints(c clientset.Interface, nodeName string, oldNode *v1.Node, newNode *v1.Node) error
- func RemoveTaintOffNode(c clientset.Interface, nodeName string, node *v1.Node, taints ...*v1.Taint) error
- func SetNodeCondition(c clientset.Interface, node types.NodeName, condition v1.NodeCondition) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddOrUpdateLabelsOnNode ¶ added in v0.17.0
func AddOrUpdateLabelsOnNode(kubeClient clientset.Interface, labelsToUpdate map[string]string, node *v1.Node) bool
AddOrUpdateLabelsOnNode updates the labels on the node and returns true on success and false on failure.
func AddOrUpdateTaintOnNode ¶
AddOrUpdateTaintOnNode add taints to the node. If taint was added into node, it'll issue API calls to update nodes; otherwise, no API calls. Return error if any.
func AddToNodeAddresses ¶
func AddToNodeAddresses(addresses *[]v1.NodeAddress, addAddresses ...v1.NodeAddress)
AddToNodeAddresses appends the NodeAddresses to the passed-by-pointer slice, only if they do not already exist
func GetNodeCondition ¶ added in v0.17.0
func GetNodeCondition(status *v1.NodeStatus, conditionType v1.NodeConditionType) (int, *v1.NodeCondition)
GetNodeCondition extracts the provided condition from the given status and returns that. Returns nil and -1 if the condition is not present, and the index of the located condition.
func PatchNodeStatus ¶ added in v0.19.0
func PatchNodeStatus(c v1core.CoreV1Interface, nodeName types.NodeName, oldNode *v1.Node, newNode *v1.Node) (*v1.Node, []byte, error)
PatchNodeStatus patches node status.
func PatchNodeTaints ¶
func PatchNodeTaints(c clientset.Interface, nodeName string, oldNode *v1.Node, newNode *v1.Node) error
PatchNodeTaints patches node's taints.
func RemoveTaintOffNode ¶ added in v0.19.0
func RemoveTaintOffNode(c clientset.Interface, nodeName string, node *v1.Node, taints ...*v1.Taint) error
RemoveTaintOffNode is for cleaning up taints temporarily added to node, won't fail if target taint doesn't exist or has been removed. If passed a node it'll check if there's anything to be done, if taint is not present it won't issue any API calls.
func SetNodeCondition ¶ added in v0.17.0
SetNodeCondition updates specific node condition with patch operation.
Types ¶
This section is empty.