bsutil

package
v1.33.1 Latest Latest
Warning

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

Go to latest
Published: May 13, 2024 License: Apache-2.0 Imports: 29 Imported by: 0

Documentation

Overview

Package bsutil package will eventually be renamed to kubeadm package after getting rid of older one

Package bsutil will eventually be renamed to kubeadm package after getting rid of older one

Package bsutil will eventually be renamed to kubeadm package after getting rid of older one

Package bsutil will eventually be renamed to kubeadm package after getting rid of older one

Package bsutil will eventually be renamed to kubeadm package after getting rid of older one

Package bsutil will eventually be renamed to kubeadm package after getting rid of older one

Package bsutil will eventually be renamed to kubeadm package after getting rid of older one

Index

Constants

View Source
const (
	// KubeadmCmdParam is command parameters for kubeadm
	KubeadmCmdParam = iota
	// KubeadmConfigParam is config parameters for kubeadm
	KubeadmConfigParam = iota
)

enum to differentiate kubeadm command line parameters from kubeadm config file parameters (see the KubeadmExtraArgsAllowed variable for more info)

View Source
const (
	// KubeletServiceFile is the file for the systemd kubelet.service
	KubeletServiceFile = "/lib/systemd/system/kubelet.service"
	// KubeletSystemdConfFile is config for the systemd kubelet.service
	KubeletSystemdConfFile = "/etc/systemd/system/kubelet.service.d/10-kubeadm.conf"
	// InitRestartWrapper is ...
	InitRestartWrapper = "/etc/init.d/.restart_wrapper.sh"
	// KubeletInitPath is where Sys-V style init script is installed
	KubeletInitPath = "/etc/init.d/kubelet"
)
View Source
const (
	Apiserver         = "apiserver"
	ControllerManager = "controller-manager"
	Scheduler         = "scheduler"
	Etcd              = "etcd"
	Kubeadm           = "kubeadm"
	Kubeproxy         = "kube-proxy"
	Kubelet           = "kubelet"
)

These are the components that can be configured through the "extra-config"

Variables

View Source
var KubeadmExtraArgsAllowed = map[int][]string{
	KubeadmCmdParam: {
		"ignore-preflight-errors",
		"dry-run",
		"kubeconfig",
		"kubeconfig-dir",
		"node-name",
		"cri-socket",
		"experimental-upload-certs",
		"certificate-key",
		"rootfs",
		"skip-phases",
	},
	KubeadmConfigParam: {
		"pod-network-cidr",
	},
}

KubeadmExtraArgsAllowed is a list of supported kubeadm params that can be supplied to kubeadm through minikube's ExtraArgs parameter. The list is split into two parts - params that can be supplied as flags on the command line and params that have to be inserted into the kubeadm config file. This is because of a kubeadm constraint which allows only certain params to be provided from the command line when the --config parameter is specified

KubeadmExtraConfigOpts is a list of allowed "extra-config" components

View Source
var SkipAdditionalPreflights = map[string][]string{}

SkipAdditionalPreflights are additional preflights we skip depending on the runtime in use.

Functions

func AdjustResourceLimits

func AdjustResourceLimits(c command.Runner) error

AdjustResourceLimits makes fine adjustments to pod resources that aren't possible via kubeadm config.

func CopyFiles added in v1.12.0

func CopyFiles(runner command.Runner, files []assets.CopyableFile) error

CopyFiles combines mkdir requests into a single call to reduce load

func CreateFlagsFromExtraArgs

func CreateFlagsFromExtraArgs(extraOptions config.ExtraOptionSlice) string

CreateFlagsFromExtraArgs converts kubeadm extra args into flags to be supplied from the command linne

func EtcdDataDir

func EtcdDataDir() string

EtcdDataDir is where etcd data is stored.

func ExistingConfig

func ExistingConfig(c command.Runner) error

ExistingConfig checks if there are config files from possible previous Kubernetes cluster

func FindInvalidExtraConfigFlags added in v1.12.0

func FindInvalidExtraConfigFlags(opts config.ExtraOptionSlice) []string

FindInvalidExtraConfigFlags returns all invalid 'extra-config' options

func GenerateKubeadmYAML

func GenerateKubeadmYAML(cc config.ClusterConfig, n config.Node, r cruntime.Manager) ([]byte, error)

GenerateKubeadmYAML generates the kubeadm.yaml file for primary control-plane node.

func HasResolvConfSearchRegression added in v1.27.0

func HasResolvConfSearchRegression(k8sVersion string) bool

HasResolvConfSearchRegression returns if the k8s version includes https://github.com/kubernetes/kubernetes/pull/109441

func InvokeKubeadm

func InvokeKubeadm(version string) string

InvokeKubeadm returns the invocation command for Kubeadm

func KubeNodeName added in v1.9.0

func KubeNodeName(cc config.ClusterConfig, n config.Node) string

KubeNodeName returns the node name registered in Kubernetes

func NewKubeletConfig

func NewKubeletConfig(mc config.ClusterConfig, nc config.Node, r cruntime.Manager) ([]byte, error)

NewKubeletConfig generates a new systemd unit containing a configured kubelet based on the options present in the KubernetesConfig.

func NewKubeletService

func NewKubeletService(cfg config.KubernetesConfig) ([]byte, error)

NewKubeletService returns a generated systemd unit file for the kubelet

func TransferBinaries

func TransferBinaries(cfg config.KubernetesConfig, c command.Runner, sm sysinit.Manager, binariesURL string) error

TransferBinaries transfers all required Kubernetes binaries

Types

This section is empty.

Directories

Path Synopsis
Package kverify verifies a running Kubernetes cluster is healthy
Package kverify verifies a running Kubernetes cluster is healthy

Jump to

Keyboard shortcuts

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