workflow

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Apr 13, 2020 License: Apache-2.0 Imports: 15 Imported by: 6

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DefaultContext

func DefaultContext(ctx context.Context) *api.WorkflowContext

func GetDefaultGlobalConfigPath

func GetDefaultGlobalConfigPath() (string, error)

func GetValetConfigDir

func GetValetConfigDir() (string, error)

func LoadDefaultGlobalConfig

func LoadDefaultGlobalConfig(store render.FileStore) (*api.ValetGlobalConfig, error)

func LoadEnv

func LoadEnv(globalConfig *api.ValetGlobalConfig) error

func LoadGlobalConfig

func LoadGlobalConfig(path string, store render.FileStore) (*api.ValetGlobalConfig, error)

Types

type Step

type Step struct {
	DnsEntry         *aws.DnsEntry          `json:"dnsEntry,omitempty"`
	Condition        *check.Condition       `json:"condition,omitempty"`
	Curl             *check.Curl            `json:"curl,omitempty"`
	WaitForPods      *check.WaitForPods     `json:"waitForPods,omitempty"`
	EnsureCluster    *cluster.EnsureCluster `json:"ensureCluster,omitempty"`
	Apply            *kubectl.Apply         `json:"apply,omitempty"`
	ApplyTemplate    *kubectl.ApplyTemplate `json:"applyTemplate,omitempty"`
	CreateSecret     *kubectl.CreateSecret  `json:"createSecret,omitempty"`
	Delete           *kubectl.Delete        `json:"delete,omitempty"`
	Patch            *kubectl.Patch         `json:"patch,omitempty"`
	InstallHelmChart *helm.InstallHelmChart `json:"installHelmChart,omitempty"`
	Bash             *script.Bash           `json:"bash,omitempty"`

	Values render.Values `json:"values,omitempty"`
	// Optional, used for identifying a specific step in a docs ref
	Id string `json:"id,omitempty"`
}

A workflow.Step is a container for an api.Step implementation. Exactly one of the member pointers should be non-nil. This makes it easy to serialize and deserialize a workflow as yaml

func Apply

func Apply(path string) *Step

func ApplyTemplate

func ApplyTemplate(path string) *Step

func Delete

func Delete(path string) *Step

func WaitForPods

func WaitForPods(namespace string) *Step

func (*Step) Get

func (s *Step) Get() api.Step

Return the actual pointer to an api.Step implementation.

func (*Step) WithId

func (s *Step) WithId(id string) *Step

func (*Step) WithValue

func (s *Step) WithValue(k, v string) *Step

type Workflow

type Workflow struct {
	SetupSteps []*Step       `json:"setup,omitempty"`
	Steps      []*Step       `json:"steps,omitempty"`
	Values     render.Values `json:"values,omitempty"`
}

func (*Workflow) Run

func (w *Workflow) Run(ctx *api.WorkflowContext) error

func (*Workflow) Setup

func (w *Workflow) Setup(ctx *api.WorkflowContext) error

Jump to

Keyboard shortcuts

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