builder

package
v0.7.0-rc3 Latest Latest
Warning

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

Go to latest
Published: Feb 15, 2023 License: MPL-2.0 Imports: 44 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// PhaseInit is the phase text for the init phase.
	PhaseInit = "Init 🚀"
	// PhaseBuild is the phase text for the build phase.
	PhaseBuild = "Build 🔧"
	// PhasePush is the phase text for the push phase.
	PhasePush = "Push Summary ⏫"
	// PhaseOutput is the phase text for the output phase.
	PhaseOutput = "Local Output Summary 🎁"
)

Variables

This section is empty.

Functions

func NewBuildError added in v0.6.15

func NewBuildError(err error, vertexLog string) error

NewBuildError creates a new BuildError with the additional output log of the command that failed

Types

type BuildError added in v0.6.15

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

BuildError contains an BuildError and log

func (*BuildError) Error added in v0.6.15

func (e *BuildError) Error() string

BuildError formats the BuildError as a string, omitting the vertex log

func (*BuildError) Unwrap added in v0.6.15

func (e *BuildError) Unwrap() error

Unwrap returns the wrapped error

func (*BuildError) VertexLog added in v0.6.15

func (e *BuildError) VertexLog() string

VertexLog returns the vertex log associated with the error

type BuildOpt added in v0.3.2

type BuildOpt struct {
	PlatformResolver           *platutil.Resolver
	AllowPrivileged            bool
	PrintPhases                bool
	Push                       bool
	CI                         bool
	NoOutput                   bool
	OnlyFinalTargetImages      bool
	OnlyArtifact               *domain.Artifact
	OnlyArtifactDestPath       string
	EnableGatewayClientLogging bool
	BuiltinArgs                variables.DefaultArgs
	GlobalWaitBlockFtr         bool
	LocalArtifactWhiteList     *gatewaycrafter.LocalArtifactWhiteList
	Logbus                     *logbus.Bus
	MainTargetDetailsFuture    chan earthfile2llb.TargetDetails
	Runner                     string
	CloudStoredAuthProvider    cloudauth.ProjectBasedAuthProvider
}

BuildOpt is a collection of build options.

type Builder

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

Builder executes Earthly builds.

func NewBuilder

func NewBuilder(ctx context.Context, opt Opt) (*Builder, error)

NewBuilder returns a new earthly Builder.

func (*Builder) BuildTarget added in v0.3.11

func (b *Builder) BuildTarget(ctx context.Context, target domain.Target, opt BuildOpt) (*states.MultiTarget, error)

BuildTarget executes the build of a given Earthly target.

type Opt added in v0.3.11

type Opt struct {
	BkClient                              *client.Client
	LogBusSolverMonitor                   *solvermon.SolverMonitor
	UseLogstream                          bool
	Console                               conslogging.ConsoleLogger
	Verbose                               bool
	Attachables                           []session.Attachable
	Enttlmnts                             []entitlements.Entitlement
	NoCache                               bool
	CacheImports                          *states.CacheImports
	CacheExport                           string
	MaxCacheExport                        string
	UseInlineCache                        bool
	SaveInlineCache                       bool
	ImageResolveMode                      llb.ResolveMode
	CleanCollection                       *cleanup.Collection
	OverridingVars                        *variables.Scope
	BuildContextProvider                  *provider.BuildContextProvider
	GitLookup                             *buildcontext.GitLookup
	UseFakeDep                            bool
	Strict                                bool
	DisableNoOutputUpdates                bool
	ParallelConversion                    bool
	Parallelism                           semutil.Semaphore
	LocalRegistryAddr                     string
	FeatureFlagOverrides                  string
	ContainerFrontend                     containerutil.ContainerFrontend
	InternalSecretStore                   *secretprovider.MutableMapStore
	InteractiveDebugging                  bool
	InteractiveDebuggingDebugLevelLogging bool
	GitImage                              string
}

Opt represent builder options.

Jump to

Keyboard shortcuts

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