Documentation
¶
Index ¶
- Variables
- type ApplyManifests
- type Backup
- type ConfigureK0s
- type Connect
- type DaemonReload
- type DefaultK0sVersion
- type DetectOS
- type Disconnect
- type EnsureJoinTokenWorkaround
- type GatherFacts
- type GatherK0sFacts
- type GenericPhase
- func (p *GenericPhase) DryMsg(host fmt.Stringer, msg string)
- func (p *GenericPhase) DryMsgf(host fmt.Stringer, msg string, args ...any)
- func (p *GenericPhase) GetConfig() *v1beta1.Cluster
- func (p *GenericPhase) IsWet() bool
- func (p *GenericPhase) Prepare(c *v1beta1.Cluster) error
- func (p *GenericPhase) SetManager(m *Manager)
- func (p *GenericPhase) Wet(host fmt.Stringer, msg string, funcs ...errorfunc) error
- type GetKubeconfig
- type InitializeK0s
- func (p *InitializeK0s) After() error
- func (p *InitializeK0s) Before() error
- func (p *InitializeK0s) CleanUp()
- func (p *InitializeK0s) Prepare(config *v1beta1.Cluster) error
- func (p *InitializeK0s) Run(ctx context.Context) error
- func (p *InitializeK0s) ShouldRun() bool
- func (p *InitializeK0s) Title() string
- type InstallBinaries
- type InstallControllers
- func (p *InstallControllers) After() error
- func (p *InstallControllers) Before() error
- func (p *InstallControllers) CleanUp()
- func (p *InstallControllers) Prepare(config *v1beta1.Cluster) error
- func (p *InstallControllers) Run(ctx context.Context) error
- func (p *InstallControllers) ShouldRun() bool
- func (p *InstallControllers) Title() string
- type InstallWorkers
- func (p *InstallWorkers) After() error
- func (p *InstallWorkers) Before() error
- func (p *InstallWorkers) CleanUp()
- func (p *InstallWorkers) Prepare(config *v1beta1.Cluster) error
- func (p *InstallWorkers) Run(ctx context.Context) error
- func (p *InstallWorkers) ShouldRun() bool
- func (p *InstallWorkers) Title() string
- type Lock
- type Manager
- type Phase
- type Phases
- type PrepareArm
- type PrepareHosts
- type Reinstall
- type ResetControllers
- func (p *ResetControllers) After() error
- func (p *ResetControllers) Before() error
- func (p *ResetControllers) DryRun() error
- func (p *ResetControllers) Prepare(config *v1beta1.Cluster) error
- func (p *ResetControllers) Run(ctx context.Context) error
- func (p *ResetControllers) ShouldRun() bool
- func (p *ResetControllers) Title() string
- type ResetLeader
- type ResetWorkers
- func (p *ResetWorkers) After() error
- func (p *ResetWorkers) Before() error
- func (p *ResetWorkers) DryRun() error
- func (p *ResetWorkers) Prepare(config *v1beta1.Cluster) error
- func (p *ResetWorkers) Run(ctx context.Context) error
- func (p *ResetWorkers) ShouldRun() bool
- func (p *ResetWorkers) Title() string
- type Restore
- type RunHooks
- type StageBinaries
- type Unlock
- type UpgradeControllers
- func (p *UpgradeControllers) After() error
- func (p *UpgradeControllers) Before() error
- func (p *UpgradeControllers) CleanUp()
- func (p *UpgradeControllers) Prepare(config *v1beta1.Cluster) error
- func (p *UpgradeControllers) Run(ctx context.Context) error
- func (p *UpgradeControllers) ShouldRun() bool
- func (p *UpgradeControllers) Title() string
- type UpgradeWorkers
- func (p *UpgradeWorkers) After() error
- func (p *UpgradeWorkers) Before() error
- func (p *UpgradeWorkers) CleanUp()
- func (p *UpgradeWorkers) Prepare(config *v1beta1.Cluster) error
- func (p *UpgradeWorkers) Run(ctx context.Context) error
- func (p *UpgradeWorkers) ShouldRun() bool
- func (p *UpgradeWorkers) Title() string
- type UploadFiles
- type ValidateEtcdMembers
- type ValidateFacts
- type ValidateHosts
Constants ¶
This section is empty.
Variables ¶
var Colorize = aurora.NewAurora(false)
Colorize is an instance of "aurora", used to colorize the output
var Force bool
Force is used by various phases to attempt a forced installation
var NoWait bool
NoWait is used by various phases to decide if node ready state should be waited for or not
Functions ¶
This section is empty.
Types ¶
type ApplyManifests ¶ added in v0.22.0
type ApplyManifests struct {
GenericPhase
// contains filtered or unexported fields
}
ApplyManifests is a phase that applies additional manifests to the cluster
func (*ApplyManifests) Prepare ¶ added in v0.22.0
func (p *ApplyManifests) Prepare(config *v1beta1.Cluster) error
Prepare the phase
func (*ApplyManifests) Run ¶ added in v0.22.0
func (p *ApplyManifests) Run(_ context.Context) error
Run the phase
func (*ApplyManifests) ShouldRun ¶ added in v0.22.0
func (p *ApplyManifests) ShouldRun() bool
ShouldRun is true when there are additional manifests to apply
func (*ApplyManifests) Title ¶ added in v0.22.0
func (p *ApplyManifests) Title() string
Title for the phase
type Backup ¶ added in v0.8.5
type Backup struct {
GenericPhase
Out io.Writer
// contains filtered or unexported fields
}
Backup connect to one of the controllers and takes a backup
type ConfigureK0s ¶
type ConfigureK0s struct {
GenericPhase
// contains filtered or unexported fields
}
ConfigureK0s writes the k0s configuration to host k0s config dir
func (*ConfigureK0s) DryRun ¶ added in v0.17.0
func (p *ConfigureK0s) DryRun() error
DryRun prints the actions that would be taken
func (*ConfigureK0s) Prepare ¶ added in v0.13.0
func (p *ConfigureK0s) Prepare(config *v1beta1.Cluster) error
Prepare the phase
func (*ConfigureK0s) ShouldRun ¶ added in v0.17.0
func (p *ConfigureK0s) ShouldRun() bool
ShouldRun is true when there are controllers to configure
type DaemonReload ¶ added in v0.17.6
type DaemonReload struct {
GenericPhase
}
DaemonReload phase runs `systemctl daemon-reload` or equivalent on all hosts.
func (*DaemonReload) Run ¶ added in v0.17.6
func (p *DaemonReload) Run(ctx context.Context) error
Run the phase
func (*DaemonReload) ShouldRun ¶ added in v0.17.6
func (p *DaemonReload) ShouldRun() bool
ShouldRun is true when there are controllers that needs to be reset
func (*DaemonReload) Title ¶ added in v0.17.6
func (p *DaemonReload) Title() string
Title for the phase
type DefaultK0sVersion ¶ added in v0.17.0
type DefaultK0sVersion struct {
GenericPhase
}
func (*DefaultK0sVersion) Run ¶ added in v0.17.0
func (p *DefaultK0sVersion) Run(_ context.Context) error
func (*DefaultK0sVersion) ShouldRun ¶ added in v0.17.0
func (p *DefaultK0sVersion) ShouldRun() bool
func (*DefaultK0sVersion) Title ¶ added in v0.17.0
func (p *DefaultK0sVersion) Title() string
type DetectOS ¶
type DetectOS struct {
GenericPhase
}
DetectOS performs remote OS detection
type Disconnect ¶
type Disconnect struct {
GenericPhase
}
Disconnect disconnects from the hosts
func (*Disconnect) DryRun ¶ added in v0.17.0
func (p *Disconnect) DryRun() error
DryRun cleans up the temporary k0s binary from the hosts
type EnsureJoinTokenWorkaround ¶ added in v0.29.0
type EnsureJoinTokenWorkaround struct {
GenericPhase
// contains filtered or unexported fields
}
EnsureJoinTokenWorkaround handles a workaround for https://github.com/k0sproject/k0s/issues/7202. On k0s v1.35.1+k0s.0, if the join token file doesn't contain a valid base64-encoded token, k0s worker will fail to start. This phase detects that condition and writes a dummy token.
func (*EnsureJoinTokenWorkaround) Prepare ¶ added in v0.29.0
func (p *EnsureJoinTokenWorkaround) Prepare(config *v1beta1.Cluster) error
Prepare finds worker hosts that need the token file workaround: - already running the affected version (token file may have been overwritten with a comment by a previous k0sctl run) - being upgraded to the affected version (token file will need to be valid base64 for the new k0s to start)
func (*EnsureJoinTokenWorkaround) Run ¶ added in v0.29.0
func (p *EnsureJoinTokenWorkaround) Run(_ context.Context) error
Run the phase
func (*EnsureJoinTokenWorkaround) ShouldRun ¶ added in v0.29.0
func (p *EnsureJoinTokenWorkaround) ShouldRun() bool
ShouldRun is true when there are affected worker hosts
func (*EnsureJoinTokenWorkaround) Title ¶ added in v0.29.0
func (p *EnsureJoinTokenWorkaround) Title() string
Title for the phase
type GatherFacts ¶
type GatherFacts struct {
GenericPhase
SkipMachineIDs bool
}
GatherFacts gathers information about hosts, such as if k0s is already up and running
type GatherK0sFacts ¶
type GatherK0sFacts struct {
GenericPhase
// contains filtered or unexported fields
}
GatherK0sFacts gathers information about hosts, such as if k0s is already up and running
func (*GatherK0sFacts) Prepare ¶ added in v0.17.0
func (p *GatherK0sFacts) Prepare(config *v1beta1.Cluster) error
Prepare finds hosts with k0s installed
func (*GatherK0sFacts) ShouldRun ¶ added in v0.17.0
func (p *GatherK0sFacts) ShouldRun() bool
ShouldRun is true when there are hosts that need to be connected
type GenericPhase ¶
GenericPhase is a basic phase which gets a config via prepare, sets it into p.Config
func (*GenericPhase) DryMsg ¶ added in v0.17.0
func (p *GenericPhase) DryMsg(host fmt.Stringer, msg string)
DryMsg is a shorthand for manager.DryMsg
func (*GenericPhase) DryMsgf ¶ added in v0.17.0
func (p *GenericPhase) DryMsgf(host fmt.Stringer, msg string, args ...any)
DryMsgf is a shorthand for manager.DryMsg + fmt.Sprintf
func (*GenericPhase) GetConfig ¶
func (p *GenericPhase) GetConfig() *v1beta1.Cluster
GetConfig is an accessor to phase Config
func (*GenericPhase) IsWet ¶ added in v0.17.0
func (p *GenericPhase) IsWet() bool
IsWet returns true when not in dry-run mode (i.e., wet mode)
func (*GenericPhase) Prepare ¶
func (p *GenericPhase) Prepare(c *v1beta1.Cluster) error
Prepare the phase
func (*GenericPhase) SetManager ¶ added in v0.15.0
func (p *GenericPhase) SetManager(m *Manager)
SetManager adds a reference to the phase manager
type GetKubeconfig ¶
type GetKubeconfig struct {
GenericPhase
APIAddress string
User string
Cluster string
}
GetKubeconfig is a phase to get and dump the admin kubeconfig
func (*GetKubeconfig) DryRun ¶ added in v0.17.0
func (p *GetKubeconfig) DryRun() error
type InitializeK0s ¶
type InitializeK0s struct {
GenericPhase
// contains filtered or unexported fields
}
InitializeK0s sets up the "initial" k0s controller
func (*InitializeK0s) After ¶ added in v0.26.0
func (p *InitializeK0s) After() error
After runs "after install" hooks for the leader controller
func (*InitializeK0s) Before ¶ added in v0.26.0
func (p *InitializeK0s) Before() error
Before runs "before install" hooks for the leader controller
func (*InitializeK0s) CleanUp ¶ added in v0.10.0
func (p *InitializeK0s) CleanUp()
CleanUp cleans up the environment override file
func (*InitializeK0s) Prepare ¶
func (p *InitializeK0s) Prepare(config *v1beta1.Cluster) error
Prepare the phase
func (*InitializeK0s) ShouldRun ¶
func (p *InitializeK0s) ShouldRun() bool
ShouldRun is true when there is a leader host
type InstallBinaries ¶ added in v0.15.1
type InstallBinaries struct {
GenericPhase
// contains filtered or unexported fields
}
InstallBinaries installs the k0s binaries from the temp location of UploadBinaries or InstallBinaries
func (*InstallBinaries) CleanUp ¶ added in v0.15.1
func (p *InstallBinaries) CleanUp()
func (*InstallBinaries) DryRun ¶ added in v0.17.0
func (p *InstallBinaries) DryRun() error
DryRun reports what would happen if Run is called.
func (*InstallBinaries) Prepare ¶ added in v0.15.1
func (p *InstallBinaries) Prepare(config *v1beta1.Cluster) error
Prepare the phase
func (*InstallBinaries) Run ¶ added in v0.15.1
func (p *InstallBinaries) Run(ctx context.Context) error
Run the phase
func (*InstallBinaries) ShouldRun ¶ added in v0.15.1
func (p *InstallBinaries) ShouldRun() bool
ShouldRun is true when the phase should be run
func (*InstallBinaries) Title ¶ added in v0.15.1
func (p *InstallBinaries) Title() string
Title for the phase
type InstallControllers ¶
type InstallControllers struct {
GenericPhase
// contains filtered or unexported fields
}
InstallControllers installs k0s controllers and joins them to the cluster
func (*InstallControllers) After ¶ added in v0.17.0
func (p *InstallControllers) After() error
After runs "after install" hooks for controller hosts and cleans up tokens
func (*InstallControllers) Before ¶ added in v0.26.0
func (p *InstallControllers) Before() error
Before runs "before install" hooks for controller hosts
func (*InstallControllers) CleanUp ¶ added in v0.10.0
func (p *InstallControllers) CleanUp()
CleanUp cleans up the environment override files on hosts
func (*InstallControllers) Prepare ¶
func (p *InstallControllers) Prepare(config *v1beta1.Cluster) error
Prepare the phase
func (*InstallControllers) Run ¶
func (p *InstallControllers) Run(ctx context.Context) error
Run the phase
func (*InstallControllers) ShouldRun ¶
func (p *InstallControllers) ShouldRun() bool
ShouldRun is true when there are controllers
type InstallWorkers ¶
type InstallWorkers struct {
GenericPhase
// contains filtered or unexported fields
}
InstallWorkers installs k0s on worker hosts and joins them to the cluster
func (*InstallWorkers) After ¶ added in v0.17.0
func (p *InstallWorkers) After() error
After runs "after install" hooks for workers
func (*InstallWorkers) Before ¶ added in v0.26.0
func (p *InstallWorkers) Before() error
Before runs "before install" hooks for workers
func (*InstallWorkers) CleanUp ¶ added in v0.10.0
func (p *InstallWorkers) CleanUp()
CleanUp attempts to clean up any changes after a failed install
func (*InstallWorkers) Prepare ¶
func (p *InstallWorkers) Prepare(config *v1beta1.Cluster) error
Prepare the phase
func (*InstallWorkers) ShouldRun ¶
func (p *InstallWorkers) ShouldRun() bool
ShouldRun is true when there are workers
type Lock ¶ added in v0.13.0
type Lock struct {
GenericPhase
// contains filtered or unexported fields
}
Lock acquires an exclusive k0sctl lock on hosts
func (*Lock) CleanUp ¶ added in v0.15.5
func (p *Lock) CleanUp()
CleanUp calls Cancel to release the lock
func (*Lock) UnlockPhase ¶ added in v0.19.1
UnlockPhase returns an unlock phase for this lock phase
type Manager ¶
type Manager struct {
Config *v1beta1.Cluster
Concurrency int
ConcurrentUploads int
DryRun bool
Writer io.Writer
// contains filtered or unexported fields
}
Manager executes phases to construct the cluster
func NewManager ¶ added in v0.16.0
NewManager creates a new Manager
type Phases ¶ added in v0.19.1
type Phases []Phase
Phases is a slice of Phases
func (Phases) Index ¶ added in v0.19.1
Index returns the index of the first occurrence matching the given phase title or -1 if not found
func (*Phases) InsertAfter ¶ added in v0.19.1
InsertAfter inserts a phase after the first occurrence of a phase with the given title
func (*Phases) InsertBefore ¶ added in v0.19.1
InsertBefore inserts a phase before the first occurrence of a phase with the given title
type PrepareArm ¶ added in v0.10.0
type PrepareArm struct {
GenericPhase
// contains filtered or unexported fields
}
PrepareArm implements a phase which fixes arm quirks
func (*PrepareArm) Prepare ¶ added in v0.10.0
func (p *PrepareArm) Prepare(config *v1beta1.Cluster) error
Prepare the phase
func (*PrepareArm) Run ¶ added in v0.10.0
func (p *PrepareArm) Run(ctx context.Context) error
Run the phase
func (*PrepareArm) ShouldRun ¶ added in v0.10.0
func (p *PrepareArm) ShouldRun() bool
ShouldRun is true when there are arm controllers
type PrepareHosts ¶
type PrepareHosts struct {
GenericPhase
}
PrepareHosts installs required packages and so on on the hosts.
type Reinstall ¶ added in v0.19.0
type Reinstall struct {
GenericPhase
// contains filtered or unexported fields
}
type ResetControllers ¶ added in v0.15.0
type ResetControllers struct {
GenericPhase
NoDrain bool
NoDelete bool
NoLeave bool
// contains filtered or unexported fields
}
ResetControllers phase removes controllers marked for reset from the kubernetes and etcd clusters and resets k0s on the host
func (*ResetControllers) After ¶ added in v0.26.0
func (p *ResetControllers) After() error
After runs "after reset" hooks
func (*ResetControllers) Before ¶ added in v0.26.0
func (p *ResetControllers) Before() error
Before runs "before reset" hooks
func (*ResetControllers) DryRun ¶ added in v0.24.0
func (p *ResetControllers) DryRun() error
DryRun reports nodes that would get reset
func (*ResetControllers) Prepare ¶ added in v0.15.0
func (p *ResetControllers) Prepare(config *v1beta1.Cluster) error
Prepare the phase
func (*ResetControllers) Run ¶ added in v0.15.0
func (p *ResetControllers) Run(ctx context.Context) error
Run the phase
func (*ResetControllers) ShouldRun ¶ added in v0.15.0
func (p *ResetControllers) ShouldRun() bool
ShouldRun is true when there are controllers that needs to be reset
func (*ResetControllers) Title ¶ added in v0.15.0
func (p *ResetControllers) Title() string
Title for the phase
type ResetLeader ¶ added in v0.15.0
type ResetLeader struct {
GenericPhase
// contains filtered or unexported fields
}
ResetLeader phase removes the leader from the cluster and thus destroys the cluster
func (*ResetLeader) After ¶ added in v0.26.0
func (p *ResetLeader) After() error
After runs "after backup" hooks
func (*ResetLeader) Before ¶ added in v0.26.0
func (p *ResetLeader) Before() error
Before runs "before reset" hooks
func (*ResetLeader) DryRun ¶ added in v0.24.0
func (p *ResetLeader) DryRun() error
DryRun reports that the host will be reset
func (*ResetLeader) Prepare ¶ added in v0.15.0
func (p *ResetLeader) Prepare(config *v1beta1.Cluster) error
Prepare the phase
func (*ResetLeader) Run ¶ added in v0.15.0
func (p *ResetLeader) Run(ctx context.Context) error
Run the phase
func (*ResetLeader) Title ¶ added in v0.15.0
func (p *ResetLeader) Title() string
Title for the phase
type ResetWorkers ¶ added in v0.15.0
type ResetWorkers struct {
GenericPhase
NoDrain bool
NoDelete bool
// contains filtered or unexported fields
}
ResetControllers phase removes workers marked for reset from the kubernetes cluster and resets k0s on the host
func (*ResetWorkers) After ¶ added in v0.26.0
func (p *ResetWorkers) After() error
After runs "after reset" hooks
func (*ResetWorkers) Before ¶ added in v0.26.0
func (p *ResetWorkers) Before() error
Before runs "before reset" hooks
func (*ResetWorkers) DryRun ¶ added in v0.24.0
func (p *ResetWorkers) DryRun() error
DryRun reports the nodes will be reset
func (*ResetWorkers) Prepare ¶ added in v0.15.0
func (p *ResetWorkers) Prepare(config *v1beta1.Cluster) error
Prepare the phase
func (*ResetWorkers) Run ¶ added in v0.15.0
func (p *ResetWorkers) Run(ctx context.Context) error
Run the phase
func (*ResetWorkers) ShouldRun ¶ added in v0.15.0
func (p *ResetWorkers) ShouldRun() bool
ShouldRun is true when there are workers that needs to be reset
func (*ResetWorkers) Title ¶ added in v0.15.0
func (p *ResetWorkers) Title() string
Title for the phase
type Restore ¶ added in v0.8.5
type Restore struct {
GenericPhase
RestoreFrom string
// contains filtered or unexported fields
}
type RunHooks ¶ added in v0.9.0
type RunHooks struct {
GenericPhase
// Action is the lifecycle action: apply, backup, reset, install, etc.
Action string
// Stage is the timing within the action: before or after.
Stage string
// contains filtered or unexported fields
}
RunHooks is a generic phase to execute per-host lifecycle hooks for a given action and stage (e.g. action "apply" with stage "before").
type StageBinaries ¶ added in v0.29.0
type StageBinaries struct {
GenericPhase
// contains filtered or unexported fields
}
StageBinaries stages k0s binaries on hosts that need them using the host's configured BinaryProvider.
func (*StageBinaries) CleanUp ¶ added in v0.29.0
func (p *StageBinaries) CleanUp()
CleanUp removes staged temp files that were not consumed (e.g. on failure).
func (*StageBinaries) DryRun ¶ added in v0.29.0
func (p *StageBinaries) DryRun() error
DryRun stages binaries in dry-run mode the same as in wet mode, because subsequent phases (e.g. config validate) need the staged binary for validation. No DryMsg/Wet messages are emitted here: staging is a local/temporary side effect, not a permanent cluster change — on success, the temp file is removed by Disconnect (including its DryRun behavior), while CleanUp is only invoked on failure paths. CleanUp is also called here on error as an extra safety net.
func (*StageBinaries) Prepare ¶ added in v0.29.0
func (p *StageBinaries) Prepare(config *v1beta1.Cluster) error
Prepare the phase
func (*StageBinaries) Run ¶ added in v0.29.0
func (p *StageBinaries) Run(ctx context.Context) error
Run the phase
func (*StageBinaries) ShouldRun ¶ added in v0.29.0
func (p *StageBinaries) ShouldRun() bool
ShouldRun is true when there are hosts that need binary staging
func (*StageBinaries) Title ¶ added in v0.29.0
func (p *StageBinaries) Title() string
Title for the phase
type Unlock ¶ added in v0.13.0
type Unlock struct {
GenericPhase
Cancel func()
}
Unlock acquires an exclusive k0sctl lock on hosts
type UpgradeControllers ¶ added in v0.5.0
type UpgradeControllers struct {
GenericPhase
// contains filtered or unexported fields
}
UpgradeControllers upgrades the controllers one-by-one
func (*UpgradeControllers) After ¶ added in v0.26.0
func (p *UpgradeControllers) After() error
After runs "after upgrade" hooks for controller hosts that were upgraded
func (*UpgradeControllers) Before ¶ added in v0.26.0
func (p *UpgradeControllers) Before() error
Before runs "before upgrade" hooks for controller hosts that need upgrade
func (*UpgradeControllers) CleanUp ¶ added in v0.10.0
func (p *UpgradeControllers) CleanUp()
CleanUp cleans up the environment override files on hosts
func (*UpgradeControllers) Prepare ¶ added in v0.5.0
func (p *UpgradeControllers) Prepare(config *v1beta1.Cluster) error
Prepare the phase
func (*UpgradeControllers) Run ¶ added in v0.5.0
func (p *UpgradeControllers) Run(ctx context.Context) error
Run the phase
func (*UpgradeControllers) ShouldRun ¶ added in v0.5.0
func (p *UpgradeControllers) ShouldRun() bool
ShouldRun is true when there are controllers that needs to be upgraded
func (*UpgradeControllers) Title ¶ added in v0.5.0
func (p *UpgradeControllers) Title() string
Title for the phase
type UpgradeWorkers ¶ added in v0.5.0
type UpgradeWorkers struct {
GenericPhase
NoDrain bool
// contains filtered or unexported fields
}
UpgradeWorkers upgrades workers in batches
func (*UpgradeWorkers) After ¶ added in v0.26.0
func (p *UpgradeWorkers) After() error
After runs "after upgrade" hooks for worker hosts that were upgraded
func (*UpgradeWorkers) Before ¶ added in v0.26.0
func (p *UpgradeWorkers) Before() error
Before runs "before upgrade" hooks for worker hosts that need upgrade
func (*UpgradeWorkers) CleanUp ¶ added in v0.10.0
func (p *UpgradeWorkers) CleanUp()
CleanUp cleans up the environment override files on hosts
func (*UpgradeWorkers) Prepare ¶ added in v0.5.0
func (p *UpgradeWorkers) Prepare(config *v1beta1.Cluster) error
Prepare the phase
func (*UpgradeWorkers) Run ¶ added in v0.5.0
func (p *UpgradeWorkers) Run(ctx context.Context) error
Run the phase
func (*UpgradeWorkers) ShouldRun ¶ added in v0.5.0
func (p *UpgradeWorkers) ShouldRun() bool
ShouldRun is true when there are workers that needs to be upgraded
func (*UpgradeWorkers) Title ¶ added in v0.5.0
func (p *UpgradeWorkers) Title() string
Title for the phase
type UploadFiles ¶ added in v0.6.0
type UploadFiles struct {
GenericPhase
// contains filtered or unexported fields
}
UploadFiles implements a phase which upload files to hosts
func (*UploadFiles) Prepare ¶ added in v0.6.0
func (p *UploadFiles) Prepare(config *v1beta1.Cluster) error
Prepare the phase
func (*UploadFiles) Run ¶ added in v0.6.0
func (p *UploadFiles) Run(ctx context.Context) error
Run the phase
func (*UploadFiles) ShouldRun ¶ added in v0.6.0
func (p *UploadFiles) ShouldRun() bool
ShouldRun is true when there are workers
func (*UploadFiles) Title ¶ added in v0.6.0
func (p *UploadFiles) Title() string
Title for the phase
type ValidateEtcdMembers ¶ added in v0.19.1
type ValidateEtcdMembers struct {
GenericPhase
// contains filtered or unexported fields
}
ValidateEtcdMembers checks for existing etcd members with the same IP as a new controller
func (*ValidateEtcdMembers) Prepare ¶ added in v0.19.1
func (p *ValidateEtcdMembers) Prepare(config *v1beta1.Cluster) error
Prepare the phase
func (*ValidateEtcdMembers) Run ¶ added in v0.19.1
func (p *ValidateEtcdMembers) Run(_ context.Context) error
Run the phase
func (*ValidateEtcdMembers) ShouldRun ¶ added in v0.19.1
func (p *ValidateEtcdMembers) ShouldRun() bool
ShouldRun is true when there are new controllers and etcd
func (*ValidateEtcdMembers) Title ¶ added in v0.19.1
func (p *ValidateEtcdMembers) Title() string
Title for the phase
type ValidateFacts ¶ added in v0.5.0
type ValidateFacts struct {
GenericPhase
SkipDowngradeCheck bool
}
ValidateFacts performs remote OS detection
func (*ValidateFacts) Run ¶ added in v0.5.0
func (p *ValidateFacts) Run(_ context.Context) error
Run the phase
func (*ValidateFacts) Title ¶ added in v0.5.0
func (p *ValidateFacts) Title() string
Title for the phase
type ValidateHosts ¶
type ValidateHosts struct {
GenericPhase
// contains filtered or unexported fields
}
ValidateHosts performs remote OS detection
Source Files
¶
- apply_manifests.go
- arm_prepare.go
- backup.go
- configure_k0s.go
- connect.go
- daemon_reload.go
- default_k0s_version.go
- detect_os.go
- disconnect.go
- ensure_join_token_workaround.go
- gather_facts.go
- gather_k0s_facts.go
- generic_phase.go
- get_kubeconfig.go
- initialize_k0s.go
- install_binaries.go
- install_controllers.go
- install_workers.go
- lock.go
- manager.go
- prepare_hosts.go
- reinstall.go
- reset_controllers.go
- reset_leader.go
- reset_workers.go
- restore.go
- run_hooks.go
- stage_binaries.go
- unlock.go
- upgrade_controllers.go
- upgrade_workers.go
- uploadfiles.go
- validate_etcd_members.go
- validate_facts.go
- validate_hosts.go