k3s

package
v0.4.6 Latest Latest
Warning

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

Go to latest
Published: Apr 1, 2024 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrExists = errors.New("k3s already installed")
	ErrNMCS   = errors.New("nm-cloud-setup is enabled, please run systemctl disable nm-cloud-setup.service nm-cloud-setup.timer and reboot")

	DefaultLocalStoragePath = filepath.Join(dataDir, "local-storage")
)
View Source
var ErrNotExist = errors.New("k3s not exists")

Functions

func Cleanup

func Cleanup(debug bool)

Cleanup runs k3s-uninstall and removes copied files if debug flag is not enabled

func ImportBundleImages

func ImportBundleImages(ctx context.Context, failFast bool) error

func ImportImages

func ImportImages(ctx context.Context, imgs map[string]string, failFast bool) error

func Install

func Install(ctx context.Context, c Config) error

Install runs K3S installation process

func Upgrade

func Upgrade(ctx context.Context, c Config) (retErr error)

func Wait

func Wait(ctx context.Context) error

Wait waits for k3s to be up

Types

type Config

type Config struct {
	*config_v1.Configuration

	Iface           string // interface for k3s network to work on
	ProxyKubernetes bool   // use proxy for k3s
	Debug           bool
	// contains filtered or unexported fields
}

type FirewallType

type FirewallType string
var (
	FirewallTypeFirewalld FirewallType = "firewalld"
	FirewallTypeUFW       FirewallType = "ufw"
)

Jump to

Keyboard shortcuts

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