build

package
v0.42.2 Latest Latest
Warning

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

Go to latest
Published: Apr 18, 2026 License: Apache-2.0 Imports: 9 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetLog added in v0.37.0

func GetLog(arg *container.Build, ids ...string) (string, error)

func StepperImages added in v0.31.0

func StepperImages(images ...string) func(build container.Build) []string

Types

type BuildCategory added in v0.30.3

type BuildCategory string

BuildCategory represents different phases of the build pipeline

const (
	Auth       BuildCategory = "auth"       // Authentication & credentials
	PreBuild   BuildCategory = "prebuild"   // Setup, protobuf, dependencies
	Build      BuildCategory = "build"      // Language-specific compilation
	PostBuild  BuildCategory = "postbuild"  // Production artifacts, packaging
	Quality    BuildCategory = "quality"    // Linting, testing, security scanning
	Apply      BuildCategory = "apply"      // Infrastructure changes
	Publish    BuildCategory = "publish"    // Publishing, releases, notifications
	PrePublish BuildCategory = "prepublish" // Publishing, releases, notifications
)

type BuildContext

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

func ToBuildContexts added in v0.2.1

func ToBuildContexts(steps ...BuildStep) []*BuildContext

func (*BuildContext) Build added in v0.37.0

func (bc *BuildContext) Build() BuildStep

type BuildResult added in v0.37.1

type BuildResult struct {
	Loop  container.BuildLoop
	Error error
	IDs   []string
}

type BuildStep added in v0.20.0

type BuildStep interface {
	Alias() string
	BuildType() *container.BuildType
	Name() string
	Images(build container.Build) []string
	IsAsync() bool
	Matches(build container.Build) bool
	RunWithBuild(build container.Build) (string, error)
}

type BuildSteps

type BuildSteps struct {
	Steps []*BuildContext

	HasAI bool
	// contains filtered or unexported fields
}

func NewBuildSteps

func NewBuildSteps(steps ...BuildStep) *BuildSteps

func (*BuildSteps) Add

func (bs *BuildSteps) Add(step BuildStep)

func (*BuildSteps) AddAfter added in v0.30.3

func (bs *BuildSteps) AddAfter(stepName string, step BuildStep) error

func (*BuildSteps) AddAsync

func (bs *BuildSteps) AddAsync(step BuildStep)

func (*BuildSteps) AddAsyncAfter added in v0.30.3

func (bs *BuildSteps) AddAsyncAfter(stepName string, step BuildStep) error

func (*BuildSteps) AddAsyncBefore added in v0.30.3

func (bs *BuildSteps) AddAsyncBefore(stepName string, step BuildStep) error

func (*BuildSteps) AddAsyncToCategory added in v0.30.3

func (bs *BuildSteps) AddAsyncToCategory(category BuildCategory, step BuildStep) error

func (*BuildSteps) AddBefore added in v0.30.3

func (bs *BuildSteps) AddBefore(stepName string, step BuildStep) error

Hook-based insertion methods

func (*BuildSteps) AddToCategory added in v0.30.3

func (bs *BuildSteps) AddToCategory(category BuildCategory, step BuildStep) error

Category-based addition methods

func (*BuildSteps) GetCategoryOrder added in v0.30.3

func (bs *BuildSteps) GetCategoryOrder() []BuildCategory

GetCategoryOrder returns the categories in the order they appear in the build steps

func (*BuildSteps) GetStepsInCategory added in v0.30.3

func (bs *BuildSteps) GetStepsInCategory(category BuildCategory) []*BuildContext

GetStepsInCategory returns all steps in a specific category

func (*BuildSteps) Images

func (bs *BuildSteps) Images(groups container.BuildGroups) []string

func (*BuildSteps) Init added in v0.2.1

func (bs *BuildSteps) Init()

func (*BuildSteps) IsNotInit added in v0.2.1

func (bs *BuildSteps) IsNotInit() bool

func (*BuildSteps) PrintSteps

func (bs *BuildSteps) PrintSteps()

func (*BuildSteps) Replace added in v0.30.3

func (bs *BuildSteps) Replace(stepName string, step BuildStep) error

Replace existing step by name

func (*BuildSteps) Run

func (bs *BuildSteps) Run(arg *container.Build, step ...string) BuildResult

func (*BuildSteps) String

func (bs *BuildSteps) String() string

type MatchesFunc added in v0.30.1

type MatchesFunc func(build container.Build) bool

type RunFunc

type RunFunc func(container.Build) (string, error)

type RunFuncv2 func(container.Build) error

type Stepper added in v0.31.0

type Stepper struct {
	RunFn      RunFunc
	MatchedFn  func(build container.Build) bool
	ImagesFn   func(build container.Build) []string
	BuildType_ container.BuildType
	Name_      string
	Alias_     string
	Async_     bool
}

func (Stepper) Alias added in v0.37.0

func (g Stepper) Alias() string

func (Stepper) BuildType added in v0.37.0

func (g Stepper) BuildType() *container.BuildType

func (Stepper) Images added in v0.31.0

func (g Stepper) Images(build container.Build) []string

func (Stepper) IsAsync added in v0.31.0

func (g Stepper) IsAsync() bool

func (Stepper) Matches added in v0.31.0

func (g Stepper) Matches(build container.Build) bool

Matches implements the Build interface provider matching logic

func (Stepper) Name added in v0.31.0

func (g Stepper) Name() string

func (Stepper) Run added in v0.31.0

func (g Stepper) Run() error

func (Stepper) RunWithBuild added in v0.31.0

func (g Stepper) RunWithBuild(build container.Build) (string, error)

Jump to

Keyboard shortcuts

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