worker

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Dec 1, 2020 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Overview

Copyright 2020 Mirantis, Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2020 Mirantis, Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2020 Mirantis, Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func KernelSetup

func KernelSetup()

KernelSetup sets the needed kernel tuning params. If setting the options fails, it only logs a warning but does not prevent the starting of worker

Types

type ContainerD

type ContainerD struct {
	LogLevel string
	K0sVars  constant.CfgVars
	// contains filtered or unexported fields
}

ContainerD implement the component interface to manage containerd as k0s component

func (*ContainerD) Healthy

func (c *ContainerD) Healthy() error

Health-check interface

func (*ContainerD) Init

func (c *ContainerD) Init() error

Init extracts the needed binaries

func (*ContainerD) Run

func (c *ContainerD) Run() error

Run runs containerD

func (*ContainerD) Stop

func (c *ContainerD) Stop() error

Stop stops containerD

type Kubelet

type Kubelet struct {
	CRISocket           string
	EnableCloudProvider bool
	K0sVars             constant.CfgVars
	KubeletConfigClient *KubeletConfigClient
	LogLevel            string
	Profile             string
	// contains filtered or unexported fields
}

Kubelet is the component implementation to manage kubelet

func (*Kubelet) Healthy

func (k *Kubelet) Healthy() error

Health-check interface

func (*Kubelet) Init

func (k *Kubelet) Init() error

Init extracts the needed binaries

func (*Kubelet) Run

func (k *Kubelet) Run() error

Run runs kubelet

func (*Kubelet) Stop

func (k *Kubelet) Stop() error

Stop stops kubelet

type KubeletConfig

type KubeletConfig struct {
	ClusterDNS    string
	ClusterDomain string
}

KubeletConfig defines the kubelet related config options

type KubeletConfigClient

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

KubeletConfigClient is the client used to fetch kubelet config from a common config map

func NewKubeletConfigClient

func NewKubeletConfigClient(kubeconfigPath string) (*KubeletConfigClient, error)

NewKubeletConfigClient creates new KubeletConfigClient using the specified kubeconfig

func (*KubeletConfigClient) Get

func (k *KubeletConfigClient) Get(profile string) (string, error)

Get reads the config from kube api

Jump to

Keyboard shortcuts

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