INNER CODE UNIT · Go

init

kubereboot/kured · cmd/kured/main.go:112

func init() {
	prometheus.MustRegister(rebootRequiredGauge)
}

func main() {

	flag.StringVar(&nodeID, "node-id", "",
		"node name kured runs on, should be passed down from spec.nodeName via KURED_NODE_ID environment variable")
	flag.BoolVar(&forceReboot, "force-reboot", false,
		"force a reboot even if the drain fails or times out")
	flag.StringVar(&metricsHost, "metrics-host", "",
		"host where metrics will listen")
	flag.IntVar(&metricsPort, "metrics-port", 8080,
		"port number where metrics will listen")
	flag.IntVar(&drainGracePeriod, "drain-grace-period", -1,
		"time in seconds given to each pod to terminate gracefully, if negative, the default value specified in the pod will be used")
	flag.StringVar(&drainPodSelector, "drain-pod-selector", "",
		"only drain pods with labels matching the selector (default: '', all pods)")

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…