kubernetesk8s.io/kubernetes/pkg/kubelet/kubeletconfig Index | Files | Directories

package kubeletconfig

import "k8s.io/kubernetes/pkg/kubelet/kubeletconfig"

Index

Types

type Controller

type Controller struct {
	// contains filtered or unexported fields
}

Controller is the controller which, among other things: - loads configuration from disk - checkpoints configuration to disk - downloads new configuration from the API server - validates configuration - tracks the last-known-good configuration, and rolls-back to last-known-good when necessary For more information, see the proposal: https://github.com/kubernetes/community/blob/master/contributors/design-proposals/node/dynamic-kubelet-configuration.md

func NewController

func NewController(defaultConfig *kubeletconfig.KubeletConfiguration,
	initConfigDir string,
	dynamicConfigDir string) (*Controller, error)

NewController constructs a new Controller object and returns it. Directory paths must be absolute. If the `initConfigDir` is an empty string, skips trying to load the init config. If the `dynamicConfigDir` is an empty string, skips trying to load checkpoints or download new config, but will still sync the ConfigOK condition if you call StartSync with a non-nil client.

func (*Controller) Bootstrap

func (cc *Controller) Bootstrap() (*kubeletconfig.KubeletConfiguration, error)

Bootstrap attempts to return a valid KubeletConfiguration based on the configuration of the Controller, or returns an error if no valid configuration could be produced. Bootstrap should be called synchronously before StartSync.

func (*Controller) StartSync

func (cc *Controller) StartSync(client clientset.Interface, nodeName string)

StartSync launches the controller's sync loops if `client` is non-nil and `nodeName` is non-empty. It will always start the Node condition reporting loop, and will also start the dynamic conifg sync loops if dynamic config is enabled on the controller. If `nodeName` is empty but `client` is non-nil, an error is logged.

Source Files

configsync.go controller.go rollback.go watch.go

Directories

PathSynopsis
pkg/kubelet/kubeletconfig/checkpoint
pkg/kubelet/kubeletconfig/checkpoint/store
pkg/kubelet/kubeletconfig/configfiles
pkg/kubelet/kubeletconfig/status
pkg/kubelet/kubeletconfig/util
pkg/kubelet/kubeletconfig/util/codec
pkg/kubelet/kubeletconfig/util/equal
pkg/kubelet/kubeletconfig/util/files
pkg/kubelet/kubeletconfig/util/log
pkg/kubelet/kubeletconfig/util/panic
pkg/kubelet/kubeletconfig/util/test
Version
v1.9.6
Published
Mar 20, 2018
Platform
js/wasm
Imports
23 packages
Last checked
15 minutes ago

Tools for package owners.