Documentation ¶
Index ¶
- Variables
- func CreateAddNodeHandler(f func(node *v1.Node) error) func(obj interface{})
- func CreateDeleteNodeHandler(f func(node *v1.Node) error) func(obj interface{})
- func CreateUpdateNodeHandler(f func(oldNode, newNode *v1.Node) error) func(oldObj, newObj interface{})
- func DeletePods(kubeClient clientset.Interface, recorder record.EventRecorder, ...) (bool, error)
- func ForcefullyDeleteNode(kubeClient clientset.Interface, nodeName string) error
- func ForcefullyDeletePod(c clientset.Interface, pod *v1.Pod) error
- func MarkAllPodsNotReady(kubeClient clientset.Interface, node *v1.Node) error
- func NodeExistsInCloudProvider(cloud cloudprovider.Interface, nodeName types.NodeName) (bool, error)
- func NodeRunningOutdatedKubelet(node *v1.Node) bool
- func RecordNodeEvent(recorder record.EventRecorder, ...)
- func RecordNodeStatusChange(recorder record.EventRecorder, node *v1.Node, newStatus string)
- func SetPodTerminationReason(kubeClient clientset.Interface, pod *v1.Pod, nodeName string) (*v1.Pod, error)
- func SwapNodeControllerTaint(kubeClient clientset.Interface, taintToAdd, taintToRemove *v1.Taint, ...) bool
Constants ¶
This section is empty.
Variables ¶
var ( // ErrCloudInstance occurs when the cloud provider does not support // the Instances API. ErrCloudInstance = errors.New("cloud provider doesn't support instances") )
Functions ¶
func CreateAddNodeHandler ¶
CreateAddNodeHandler creates an add node handler.
func CreateDeleteNodeHandler ¶
CreateDeleteNodeHandler creates a delete node handler.
func CreateUpdateNodeHandler ¶
func CreateUpdateNodeHandler(f func(oldNode, newNode *v1.Node) error) func(oldObj, newObj interface{})
CreateUpdateNodeHandler creates a node update handler.
func DeletePods ¶
func DeletePods(kubeClient clientset.Interface, recorder record.EventRecorder, nodeName, nodeUID string, daemonStore extensionslisters.DaemonSetLister) (bool, error)
DeletePods will delete all pods from master running on given node, and return true if any pods were deleted, or were found pending deletion.
func ForcefullyDeleteNode ¶
ForcefullyDeleteNode deletes the node immediately. The pods on the node are cleaned up by the podGC.
func ForcefullyDeletePod ¶
ForcefullyDeletePod deletes the pod immediately.
func MarkAllPodsNotReady ¶
MarkAllPodsNotReady updates ready status of all pods running on given node from master return true if success
func NodeExistsInCloudProvider ¶
func NodeExistsInCloudProvider(cloud cloudprovider.Interface, nodeName types.NodeName) (bool, error)
NodeExistsInCloudProvider returns true if the node exists in the cloud provider.
func NodeRunningOutdatedKubelet ¶
NodeRunningOutdatedKubelet returns true if the kubeletVersion reported in the nodeInfo of the given node is "outdated", meaning < 1.2.0. Older versions were inflexible and modifying pod.Status directly through the apiserver would result in unexpected outcomes.
func RecordNodeEvent ¶
func RecordNodeEvent(recorder record.EventRecorder, nodeName, nodeUID, eventtype, reason, event string)
RecordNodeEvent records a event related to a node.
func RecordNodeStatusChange ¶
func RecordNodeStatusChange(recorder record.EventRecorder, node *v1.Node, newStatus string)
RecordNodeStatusChange records a event related to a node status change.
Types ¶
This section is empty.