node

package
v3.8.0-0.10.0+incompat... Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 23, 2017 License: Apache-2.0 Imports: 31 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SetFakeCadvisorInterfaceForIntegrationTest

func SetFakeCadvisorInterfaceForIntegrationTest()

SetFakeCadvisorInterfaceForIntegrationTest sets a fake cadvisor implementation to allow the node to run in integration tests

func SetFakeContainerManagerInterfaceForIntegrationTest

func SetFakeContainerManagerInterfaceForIntegrationTest()

SetFakeContainerManagerInterfaceForIntegrationTest sets a fake container manager implementation to allow the node to run in integration tests

Types

type NodeConfig

type NodeConfig struct {
	// BindAddress is the address to bind to
	BindAddress string
	// VolumeDir is the directory that volumes will be stored under
	VolumeDir string
	// AllowDisabledDocker if true, will make the Kubelet ignore errors from Docker
	AllowDisabledDocker bool
	// Containerized is true if we are expected to be running inside of a container
	Containerized bool
	// DNSClient is a client that is only used to lookup default DNS IP addresses on
	// the cluster. It should not be passed into the Kubelet.
	DNSClient kclientsetexternal.Interface

	// DockerClient is a client to connect to Docker
	DockerClient dockertools.Interface
	// KubeletServer contains the KubeletServer configuration
	KubeletServer *kubeletoptions.KubeletServer
	// KubeletDeps are the injected code dependencies for the kubelet, fully initialized
	KubeletDeps *kubelet.Dependencies
}

NodeConfig represents the required parameters to start the OpenShift node through Kubernetes. All fields are required.

func New

func (*NodeConfig) EnsureDocker

func (c *NodeConfig) EnsureDocker(docker *dockerutil.Helper)

EnsureDocker attempts to connect to the Docker daemon defined by the helper, and if it is unable to it will print a warning.

func (*NodeConfig) EnsureKubeletAccess

func (c *NodeConfig) EnsureKubeletAccess()

EnsureKubeletAccess performs a number of test operations that the Kubelet requires to properly function. All errors here are fatal.

func (*NodeConfig) EnsureLocalQuota

func (c *NodeConfig) EnsureLocalQuota(nodeConfig configapi.NodeConfig)

EnsureLocalQuota checks if the node config specifies a local storage perFSGroup quota, and if so will test that the volumeDirectory is on a filesystem suitable for quota enforcement. If checks pass the k8s emptyDir volume plugin will be replaced with a wrapper version which adds quota functionality.

func (*NodeConfig) EnsureVolumeDir

func (c *NodeConfig) EnsureVolumeDir()

EnsureVolumeDir attempts to convert the provided volume directory argument to an absolute path and create the directory if it does not exist. Will exit if an error is encountered.

func (*NodeConfig) HandleDockerError

func (c *NodeConfig) HandleDockerError(message string)

HandleDockerError handles an an error from the docker daemon

func (*NodeConfig) RunKubelet

func (c *NodeConfig) RunKubelet()

RunKubelet starts the Kubelet.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL