bootstrap

package
v3.1.7 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2024 License: Apache-2.0 Imports: 14 Imported by: 1

Documentation

Overview

Package bootstrap defines the CAPKK bootstrap operations on the remote instance.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

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

Service holds a collection of interfaces. The interfaces are broken down like this to group functions together.

func NewService

func NewService(sshClient ssh.Interface, scope scope.LBScope, instanceScope *scope.InstanceScope) *Service

NewService returns a new service given the remote instance kubekey build-in bootstrap provision client.

func (*Service) AddUsers

func (s *Service) AddUsers() error

AddUsers adds a kube user to the Linux.

func (*Service) CreateDirectory

func (s *Service) CreateDirectory() error

CreateDirectory creates some common directories.

func (*Service) DaemonReload

func (s *Service) DaemonReload() error

DaemonReload reloads the systemd daemon and restart the containerd.

func (*Service) ExecInitScript

func (s *Service) ExecInitScript() error

ExecInitScript executes the init script on the remote instance.

func (*Service) KubeadmReset

func (s *Service) KubeadmReset(criSocket string) error

KubeadmReset resets the Kubernetes by using kubeadm.

func (*Service) RemoveFiles

func (s *Service) RemoveFiles() error

RemoveFiles removes some directories and files that may have been created by the Kubernetes and other related components.

func (*Service) ResetNetwork

func (s *Service) ResetNetwork() error

ResetNetwork resets the network configuration.

func (*Service) ResetTmpDirectory

func (s *Service) ResetTmpDirectory() error

ResetTmpDirectory resets the temporary "/tmp/kubekey" directory.

func (*Service) SetHostname

func (s *Service) SetHostname() error

SetHostname sets the hostname of the machine.

func (*Service) UninstallK3s

func (s *Service) UninstallK3s() error

UninstallK3s uninstalls the k3s.

Jump to

Keyboard shortcuts

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