tasks

package
v1.2.0-beta.1 Latest Latest
Warning

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

Go to latest
Published: Feb 17, 2021 License: Apache-2.0 Imports: 46 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Task

type Task struct {
	Fn         func(*state.State) error
	Predicate  func(*state.State) bool
	Desciption string
	ErrMsg     string
	Retries    int
}

Task is a runnable task

func (*Task) Run

func (t *Task) Run(s *state.State) error

Run runs a task

type Tasks

type Tasks []Task

func WithBinariesOnly

func WithBinariesOnly(t Tasks) Tasks

WithBinariesOnly will prepend passed tasks with tasks WithHostnameOS() and append install prerequisite binaries (docker, kubeadm, kubelet, etc...) on all hosts

func WithClusterStatus

func WithClusterStatus(t Tasks) Tasks

func WithFullInstall

func WithFullInstall(t Tasks) Tasks

WithFullInstall with install binaries (using WithBinariesOnly) and orchestrate complete cluster init

func WithHostnameOS

func WithHostnameOS(t Tasks) Tasks

WithHostnameOS will prepend passed tasks with 2 basic tasks:

  • detect OS on all cluster hosts
  • detect hostnames on all cluster hosts

func WithProbes

func WithProbes(t Tasks) Tasks

WithProbes will run different probes over the defined cluster

func WithRefreshResources

func WithRefreshResources(t Tasks) Tasks

func WithReset

func WithReset(t Tasks) Tasks

func WithUpgrade

func WithUpgrade(t Tasks) Tasks

func (Tasks) Descriptions

func (t Tasks) Descriptions(s *state.State) []string

func (Tasks) Run

func (t Tasks) Run(s *state.State) error

Jump to

Keyboard shortcuts

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