runner

package
v1.39.0 Latest Latest
Warning

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

Go to latest
Published: Jun 23, 2022 License: Apache-2.0 Imports: 41 Imported by: 2

Documentation

Index

Constants

View Source
const (
	RemoteDigestSource = "remote"
	NoneDigestSource   = "none"
	TagDigestSource    = "tag"
)

Variables

View Source
var ErrorConfigurationChanged = errors.New("configuration changed")

ErrorConfigurationChanged is a special error that's returned when the skaffold configuration was changed.

Functions

func CheckWorkspaces added in v1.24.0

func CheckWorkspaces(artifacts []*latest.Artifact) error

func GetBuilder added in v1.24.0

GetBuilder creates a builder from a given RunContext and build pipeline type.

func GetDeployer added in v1.27.0

func GetDeployer(ctx context.Context, runCtx *runcontext.RunContext, labeller *label.DefaultLabeller) (deploy.Deployer, error)

GetDeployer creates a deployer from a given RunContext and deploy pipeline definitions.

func WithNotification added in v0.6.1

func WithNotification(d deploy.Deployer) deploy.Deployer

WithNotification creates a deployer that bips each time a deploy is done.

func WithTimings added in v0.6.1

func WithTimings(b build.Builder, t test.Tester, d deploy.Deployer, cacheArtifacts bool) (build.Builder, test.Tester, deploy.Deployer)

WithTimings creates a deployer that logs the duration of each phase.

Types

type Builder added in v1.23.0

type Builder struct {
	Builder build.Builder

	Builds []graph.Artifact
	// contains filtered or unexported fields
}

func NewBuilder added in v1.24.0

func NewBuilder(builder build.Builder, tagger tag.Tagger, platforms platform.Resolver, cache cache.Cache, runCtx *runcontext.RunContext) *Builder

func (*Builder) ApplyDefaultRepo added in v1.23.0

func (r *Builder) ApplyDefaultRepo(tag string) (string, error)

ApplyDefaultRepo applies the default repo to a given image tag.

func (*Builder) Build added in v1.23.0

func (r *Builder) Build(ctx context.Context, out io.Writer, artifacts []*latest.Artifact) ([]graph.Artifact, error)

Build builds a list of artifacts.

func (*Builder) GetBuilds added in v1.24.0

func (r *Builder) GetBuilds() []graph.Artifact

GetBuilds returns the builds value.

func (*Builder) HasBuilt added in v1.23.0

func (r *Builder) HasBuilt() bool

HasBuilt returns true if this runner has built something.

type ChangeSet added in v1.23.0

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

func (*ChangeSet) AddRebuild added in v1.23.0

func (c *ChangeSet) AddRebuild(a *latest.Artifact)

func (*ChangeSet) AddResync added in v1.23.0

func (c *ChangeSet) AddResync(s *sync.Item)

func (*ChangeSet) AddRetest added in v1.23.0

func (c *ChangeSet) AddRetest(a *latest.Artifact)

func (*ChangeSet) NeedsRebuild added in v1.24.0

func (c *ChangeSet) NeedsRebuild() []*latest.Artifact

NeedsRebuild gets the value of needsRebuild, which itself is not expected to be changed outside ChangeSet

func (*ChangeSet) NeedsRedeploy added in v1.24.0

func (c *ChangeSet) NeedsRedeploy() bool

NeedsRedeploy gets the value of needsRedeploy, which itself is not expected to be changed outside ChangeSet

func (*ChangeSet) NeedsReload added in v1.24.0

func (c *ChangeSet) NeedsReload() bool

NeedsReload gets the value of needsReload, which itself is not expected to be changed outside ChangeSet

func (*ChangeSet) NeedsResync added in v1.24.0

func (c *ChangeSet) NeedsResync() []*sync.Item

NeedsResync gets the value of needsResync, which itself is not expected to be changed outside ChangeSet

func (*ChangeSet) NeedsRetest added in v1.24.0

func (c *ChangeSet) NeedsRetest() map[string]bool

NeedsRetest gets the value of needsRetest, which itself is not expected to be changed outside ChangeSet

func (*ChangeSet) Redeploy added in v1.24.0

func (c *ChangeSet) Redeploy()

Redeploy marks that deploy is expected to happen.

func (*ChangeSet) Reload added in v1.24.0

func (c *ChangeSet) Reload()

Reload marks that reload is expected to happen.

func (*ChangeSet) ResetBuild added in v1.24.0

func (c *ChangeSet) ResetBuild()

func (*ChangeSet) ResetDeploy added in v1.24.0

func (c *ChangeSet) ResetDeploy()

func (*ChangeSet) ResetSync added in v1.24.0

func (c *ChangeSet) ResetSync()

func (*ChangeSet) ResetTest added in v1.24.0

func (c *ChangeSet) ResetTest()

type Intents added in v1.23.0

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

func NewIntents added in v1.24.0

func NewIntents(autoBuild, autoSync, autoDeploy bool) *Intents

func (*Intents) GetAutoBuild added in v1.24.0

func (i *Intents) GetAutoBuild() bool

func (*Intents) GetAutoDeploy added in v1.24.0

func (i *Intents) GetAutoDeploy() bool

func (*Intents) GetAutoDevloop added in v1.33.0

func (i *Intents) GetAutoDevloop() bool

func (*Intents) GetAutoSync added in v1.24.0

func (i *Intents) GetAutoSync() bool

func (*Intents) GetIntents added in v1.23.0

func (i *Intents) GetIntents() (bool, bool, bool)

GetIntents returns build, sync, and deploy intents (in that order) If intent is devloop intent, all are returned true

func (*Intents) GetIntentsAttrs added in v1.24.0

func (i *Intents) GetIntentsAttrs() (bool, bool, bool)

GetIntentsAttrs returns the intent attributes for testing only.

func (*Intents) IsAnyAutoEnabled added in v1.23.0

func (i *Intents) IsAnyAutoEnabled() bool

func (*Intents) Reset added in v1.24.0

func (i *Intents) Reset()

func (*Intents) ResetBuild added in v1.24.0

func (i *Intents) ResetBuild()

func (*Intents) ResetDeploy added in v1.24.0

func (i *Intents) ResetDeploy()

func (*Intents) ResetSync added in v1.24.0

func (i *Intents) ResetSync()

func (*Intents) SetAutoBuild added in v1.24.0

func (i *Intents) SetAutoBuild(val bool)

func (*Intents) SetAutoDeploy added in v1.24.0

func (i *Intents) SetAutoDeploy(val bool)

func (*Intents) SetAutoDevloop added in v1.33.0

func (i *Intents) SetAutoDevloop(val bool)

func (*Intents) SetAutoSync added in v1.24.0

func (i *Intents) SetAutoSync(val bool)

func (*Intents) SetBuild added in v1.24.0

func (i *Intents) SetBuild(val bool)

func (*Intents) SetDeploy added in v1.24.0

func (i *Intents) SetDeploy(val bool)

func (*Intents) SetDevloop added in v1.33.0

func (i *Intents) SetDevloop(val bool)

func (*Intents) SetSync added in v1.24.0

func (i *Intents) SetSync(val bool)

type Listener added in v0.34.0

type Listener interface {
	WatchForChanges(context.Context, io.Writer, func() error) error
	LogWatchToUser(io.Writer)
}

type Pruner added in v1.23.0

type Pruner struct {
	build.Builder
}

func (*Pruner) Prune added in v1.23.0

func (r *Pruner) Prune(ctx context.Context, out io.Writer) error

type Runner added in v0.33.0

Runner is responsible for running the skaffold build, test and deploy config.

type SkaffoldListener added in v0.34.0

type SkaffoldListener struct {
	Monitor filemon.Monitor
	Trigger trigger.Trigger
	// contains filtered or unexported fields
}

func NewSkaffoldListener added in v1.24.0

func NewSkaffoldListener(monitor filemon.Monitor, trigger trigger.Trigger, cache graph.SourceDependenciesCache,
	intentChan <-chan bool) *SkaffoldListener

func (*SkaffoldListener) LogWatchToUser added in v0.34.0

func (l *SkaffoldListener) LogWatchToUser(out io.Writer)

func (*SkaffoldListener) WatchForChanges added in v0.34.0

func (l *SkaffoldListener) WatchForChanges(ctx context.Context, out io.Writer, devLoop func() error) error

WatchForChanges listens to a trigger, and when one is received, computes file changes and conditionally runs the dev loop.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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