node

package
v1.32.0 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2023 License: Apache-2.0 Imports: 58 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Add

func Add(cc *config.ClusterConfig, n config.Node, delOnFail bool) error

Add adds a new node config to an existing cluster.

func CacheAndLoadImagesInConfig

func CacheAndLoadImagesInConfig(profiles []*config.Profile) error

CacheAndLoadImagesInConfig loads the images currently in the config file called by 'start' and 'cache reload' commands.

func CacheKubectlBinary

func CacheKubectlBinary(k8sVersion, binaryURL string) (string, error)

CacheKubectlBinary caches the kubectl binary

func Delete

func Delete(cc config.ClusterConfig, name string) (*config.Node, error)

Delete calls drainNode to remove node from cluster and deletes the host.

func ExitIfFatal added in v1.13.0

func ExitIfFatal(err error, force bool)

ExitIfFatal before exiting will try to check for different error types and provide advice if we know for sure what the error is

func Name added in v1.9.0

func Name(index int) string

Name returns the appropriate name for the node given the current number of nodes

func Provision added in v1.10.0

func Provision(cc *config.ClusterConfig, n *config.Node, apiServer bool, delOnFail bool) (command.Runner, bool, libmachine.API, *host.Host, error)

Provision provisions the machine/container for the node

func Retrieve

func Retrieve(cc config.ClusterConfig, name string) (*config.Node, int, error)

Retrieve finds the node by name in the given cluster

func Save

func Save(cfg *config.ClusterConfig, node *config.Node) error

Save saves a node to a cluster

func Start

func Start(starter Starter, apiServer bool) (*kubeconfig.Settings, error)

Start spins up a guest and starts the Kubernetes node.

Types

type Starter added in v1.10.0

type Starter struct {
	Runner         command.Runner
	PreExists      bool
	StopK8s        bool
	MachineAPI     libmachine.API
	Host           *host.Host
	Cfg            *config.ClusterConfig
	Node           *config.Node
	ExistingAddons map[string]bool
}

Starter is a struct with all the necessary information to start a node

Jump to

Keyboard shortcuts

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