Documentation ¶
Index ¶
- Constants
- Variables
- func DeleteTaint(taints []v1.Taint, taintToDelete *v1.Taint) ([]v1.Taint, bool)
- func GetDeploymentNamespace() (string, error)
- func GetLinuxUptime() (time.Duration, error)
- func GetSelfNodeRemediationAgentPod(nodeName string, r client.Reader) (*v1.Pod, error)
- func InitOutOfServiceTaintFlags(config *rest.Config) error
- func IsSoftwareRebootEnabled() (bool, error)
- func TaintExists(taints []v1.Taint, taintToFind *v1.Taint) bool
- func UpdateNodeWithIsRebootCapableAnnotation(watchdogInitiated bool, nodeName string, mgr manager.Manager) error
Constants ¶
View Source
const ( // IsRebootCapableAnnotation value is the key name for the node's annotation that will determine if node is reboot capable IsRebootCapableAnnotation = "is-reboot-capable.self-node-remediation.medik8s.io" IsSoftwareRebootEnabledEnvVar = "IS_SOFTWARE_REBOOT_ENABLED" )
Variables ¶
View Source
var ( //IsOutOfServiceTaintSupported will be set to true in case OutOfServiceTaint is supported (k8s 1.26 or higher) IsOutOfServiceTaintSupported bool //IsOutOfServiceTaintGA will be set to true in case OutOfServiceTaint is GA (k8s 1.28 or higher) IsOutOfServiceTaintGA bool )
Functions ¶
func DeleteTaint ¶
DeleteTaint removes all the taints that have the same key and effect to given taintToDelete.
func GetDeploymentNamespace ¶
GetDeploymentNamespace returns the Namespace this operator is deployed on.
func GetLinuxUptime ¶
GetLinuxUptime returns the uptime of a linux host
func InitOutOfServiceTaintFlags ¶ added in v0.8.0
func IsSoftwareRebootEnabled ¶
func TaintExists ¶
TaintExists checks if the given taint exists in list of taints. Returns true if exists false otherwise.
func UpdateNodeWithIsRebootCapableAnnotation ¶
func UpdateNodeWithIsRebootCapableAnnotation(watchdogInitiated bool, nodeName string, mgr manager.Manager) error
UpdateNodeWithIsRebootCapableAnnotation updates the is-reboot-capable node annotation to be true if any kind of reboot is enabled and false if there isn't watchdog and software reboot is disabled
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.