Documentation ¶
Index ¶
- func ImageLogProcessStyle(isArtifact bool) *style.Style
- func ImageLogTagStyle(isArtifact bool) *style.Style
- type BaseImageType
- type BasePhase
- type BuildOptions
- type BuildPhase
- func (phase *BuildPhase) AfterImageStages(ctx context.Context, img *Image) error
- func (phase *BuildPhase) AfterImages(ctx context.Context) error
- func (phase *BuildPhase) BeforeImageStages(_ context.Context, img *Image) error
- func (phase *BuildPhase) BeforeImages(_ context.Context) error
- func (phase *BuildPhase) Clone() Phase
- func (phase *BuildPhase) ImageProcessingShouldBeStopped(_ context.Context, img *Image) bool
- func (phase *BuildPhase) Name() string
- func (phase *BuildPhase) OnImageStage(ctx context.Context, img *Image, stg stage.Interface) error
- type BuildPhaseOptions
- type Conveyor
- func (c *Conveyor) AppendOnTerminateFunc(f func() error)
- func (c *Conveyor) Build(ctx context.Context, opts BuildOptions) error
- func (c *Conveyor) FetchLastImageStage(ctx context.Context, imageName string) error
- func (c *Conveyor) GetBaseImagesRepoErrCache(key string) error
- func (c *Conveyor) GetBaseImagesRepoIdsCache(key string) string
- func (c *Conveyor) GetGitRepoCaches() map[string]*stage.GitRepoCache
- func (c *Conveyor) GetImage(name string) *Image
- func (c *Conveyor) GetImageContentSignature(imageName string) string
- func (c *Conveyor) GetImageIDForImageStage(imageName, stageName string) string
- func (c *Conveyor) GetImageIDForLastImageStage(imageName string) string
- func (c *Conveyor) GetImageInfoGetters() (images []*image.InfoGetter)
- func (c *Conveyor) GetImageNameForImageStage(imageName, stageName string) string
- func (c *Conveyor) GetImageNameForLastImageStage(imageName string) string
- func (c *Conveyor) GetImageStageContentSignature(imageName, stageName string) string
- func (c *Conveyor) GetImageTmpDir(imageName string) string
- func (c *Conveyor) GetImportServer(ctx context.Context, imageName, stageName string) (import_server.ImportServer, error)
- func (c *Conveyor) GetLocalGitRepo() *git_repo.Local
- func (c *Conveyor) GetLocalGitRepoVirtualMergeOptions() stage.VirtualMergeOptions
- func (c *Conveyor) GetOrCreateGitRepoCache(gitRepoName string) *stage.GitRepoCache
- func (c *Conveyor) GetOrCreateStageImage(fromImage *container_runtime.StageImage, name string) *container_runtime.StageImage
- func (c *Conveyor) GetProjectRepoCommit(ctx context.Context) (string, error)
- func (c *Conveyor) GetRemoteGitRepo(key string) *git_repo.Remote
- func (c *Conveyor) GetStageID(imageName string) string
- func (c *Conveyor) GetStageImage(name string) *container_runtime.StageImage
- func (c *Conveyor) GetStageSignatureMutex(stage string) *sync.Mutex
- func (c *Conveyor) Init() error
- func (c *Conveyor) IsBaseImagesRepoErrCacheExist(key string) bool
- func (c *Conveyor) IsBaseImagesRepoIdsCacheExist(key string) bool
- func (c *Conveyor) SetBaseImagesRepoErrCache(key string, err error)
- func (c *Conveyor) SetBaseImagesRepoIdsCache(key, value string)
- func (c *Conveyor) SetLocalGitRepo(repo *git_repo.Local)
- func (c *Conveyor) SetRemoteGitRepo(key string, repo *git_repo.Remote)
- func (c *Conveyor) SetStageImage(stageImage *container_runtime.StageImage)
- func (c *Conveyor) ShouldBeBuilt(ctx context.Context) error
- func (c *Conveyor) Terminate(ctx context.Context) error
- func (c *Conveyor) UnsetStageImage(name string)
- type ConveyorOptions
- type ConveyorWithRetryWrapper
- type Image
- func (i *Image) FetchBaseImage(ctx context.Context, c *Conveyor) error
- func (i *Image) GetBaseImage() *container_runtime.StageImage
- func (i *Image) GetContentSignature() string
- func (i *Image) GetImageInfoGetter() *image.InfoGetter
- func (i *Image) GetLastNonEmptyStage() stage.Interface
- func (i *Image) GetLogName() string
- func (i *Image) GetName() string
- func (i *Image) GetStage(name stage.StageName) stage.Interface
- func (i *Image) GetStageID() string
- func (i *Image) GetStages() []stage.Interface
- func (i *Image) LogDetailedName() string
- func (i *Image) LogName() string
- func (i *Image) LogProcessStyle() *style.Style
- func (i *Image) LogTagStyle() *style.Style
- func (i *Image) SetContentSignature(sig string)
- func (i *Image) SetLastNonEmptyStage(stg stage.Interface)
- func (i *Image) SetStages(stages []stage.Interface)
- func (i *Image) SetupBaseImage(c *Conveyor)
- type IntrospectOptions
- type IntrospectTarget
- type Phase
- type Report
- type ReportFormat
- type ReportImageRecord
- type StagesIterator
- func (iterator *StagesIterator) GetPrevBuiltImage(img *Image, stg stage.Interface) container_runtime.ImageInterface
- func (iterator *StagesIterator) GetPrevImage(img *Image, stg stage.Interface) container_runtime.ImageInterface
- func (iterator *StagesIterator) OnImageStage(ctx context.Context, img *Image, stg stage.Interface, ...) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ImageLogProcessStyle ¶
func ImageLogTagStyle ¶
Types ¶
type BaseImageType ¶
type BaseImageType string
const ( ImageFromRegistryAsBaseImage BaseImageType = "ImageFromRegistryBaseImage" StageAsBaseImage BaseImageType = "StageBaseImage" )
type BuildOptions ¶ added in v1.2.0
type BuildOptions struct { ImageBuildOptions container_runtime.BuildOptions IntrospectOptions ReportPath string ReportFormat ReportFormat DryRun bool }
type BuildPhase ¶
type BuildPhase struct { BasePhase BuildPhaseOptions StagesIterator *StagesIterator ShouldAddManagedImageRecord bool Report *Report ReportPath string ReportFormat ReportFormat }
func NewBuildPhase ¶
func NewBuildPhase(c *Conveyor, opts BuildPhaseOptions) *BuildPhase
func (*BuildPhase) AfterImageStages ¶
func (phase *BuildPhase) AfterImageStages(ctx context.Context, img *Image) error
func (*BuildPhase) AfterImages ¶
func (phase *BuildPhase) AfterImages(ctx context.Context) error
func (*BuildPhase) BeforeImageStages ¶
func (phase *BuildPhase) BeforeImageStages(_ context.Context, img *Image) error
func (*BuildPhase) BeforeImages ¶
func (phase *BuildPhase) BeforeImages(_ context.Context) error
func (*BuildPhase) Clone ¶ added in v1.1.23
func (phase *BuildPhase) Clone() Phase
func (*BuildPhase) ImageProcessingShouldBeStopped ¶
func (phase *BuildPhase) ImageProcessingShouldBeStopped(_ context.Context, img *Image) bool
func (*BuildPhase) Name ¶
func (phase *BuildPhase) Name() string
func (*BuildPhase) OnImageStage ¶
type BuildPhaseOptions ¶
type BuildPhaseOptions struct { BuildOptions ShouldBeBuiltMode bool }
type Conveyor ¶
type Conveyor struct { ContainerRuntime container_runtime.ContainerRuntime StorageLockManager storage.LockManager StorageManager *manager.StorageManager ConveyorOptions // contains filtered or unexported fields }
func NewConveyor ¶
func NewConveyor(werfConfig *config.WerfConfig, imageNamesToProcess []string, projectDir, baseTmpDir, sshAuthSock string, containerRuntime container_runtime.ContainerRuntime, storageManager *manager.StorageManager, storageLockManager storage.LockManager, opts ConveyorOptions) (*Conveyor, error)
func (*Conveyor) AppendOnTerminateFunc ¶
func (*Conveyor) Build ¶ added in v1.2.0
func (c *Conveyor) Build(ctx context.Context, opts BuildOptions) error
func (*Conveyor) FetchLastImageStage ¶ added in v1.2.0
func (*Conveyor) GetBaseImagesRepoErrCache ¶ added in v1.1.23
func (*Conveyor) GetBaseImagesRepoIdsCache ¶ added in v1.1.23
func (*Conveyor) GetGitRepoCaches ¶ added in v1.1.23
func (c *Conveyor) GetGitRepoCaches() map[string]*stage.GitRepoCache
func (*Conveyor) GetImageContentSignature ¶
func (*Conveyor) GetImageIDForImageStage ¶
func (*Conveyor) GetImageIDForLastImageStage ¶
func (*Conveyor) GetImageInfoGetters ¶
func (c *Conveyor) GetImageInfoGetters() (images []*image.InfoGetter)
func (*Conveyor) GetImageNameForImageStage ¶
func (*Conveyor) GetImageNameForLastImageStage ¶
func (*Conveyor) GetImageStageContentSignature ¶
func (*Conveyor) GetImageTmpDir ¶
func (*Conveyor) GetImportServer ¶
func (c *Conveyor) GetImportServer(ctx context.Context, imageName, stageName string) (import_server.ImportServer, error)
func (*Conveyor) GetLocalGitRepo ¶
func (*Conveyor) GetLocalGitRepoVirtualMergeOptions ¶
func (c *Conveyor) GetLocalGitRepoVirtualMergeOptions() stage.VirtualMergeOptions
func (*Conveyor) GetOrCreateGitRepoCache ¶ added in v1.1.23
func (c *Conveyor) GetOrCreateGitRepoCache(gitRepoName string) *stage.GitRepoCache
func (*Conveyor) GetOrCreateStageImage ¶
func (c *Conveyor) GetOrCreateStageImage(fromImage *container_runtime.StageImage, name string) *container_runtime.StageImage
func (*Conveyor) GetProjectRepoCommit ¶
func (*Conveyor) GetRemoteGitRepo ¶ added in v1.1.23
func (*Conveyor) GetStageID ¶ added in v1.2.0
func (*Conveyor) GetStageImage ¶
func (c *Conveyor) GetStageImage(name string) *container_runtime.StageImage
func (*Conveyor) GetStageSignatureMutex ¶ added in v1.1.23
func (*Conveyor) IsBaseImagesRepoErrCacheExist ¶ added in v1.1.23
func (*Conveyor) IsBaseImagesRepoIdsCacheExist ¶ added in v1.1.23
func (*Conveyor) SetBaseImagesRepoErrCache ¶ added in v1.1.23
func (*Conveyor) SetBaseImagesRepoIdsCache ¶ added in v1.1.23
func (*Conveyor) SetLocalGitRepo ¶
func (*Conveyor) SetRemoteGitRepo ¶ added in v1.1.23
func (*Conveyor) SetStageImage ¶
func (c *Conveyor) SetStageImage(stageImage *container_runtime.StageImage)
func (*Conveyor) UnsetStageImage ¶
type ConveyorOptions ¶
type ConveyorWithRetryWrapper ¶
type ConveyorWithRetryWrapper struct { WerfConfig *config.WerfConfig ImageNamesToProcess []string ProjectDir string BaseTmpDir string SshAuthSock string ContainerRuntime container_runtime.ContainerRuntime StorageManager *manager.StorageManager StorageLockManager storage.LockManager ConveyorOptions ConveyorOptions }
func NewConveyorWithRetryWrapper ¶
func NewConveyorWithRetryWrapper(werfConfig *config.WerfConfig, imageNamesToProcess []string, projectDir, baseTmpDir, sshAuthSock string, containerRuntime container_runtime.ContainerRuntime, storageManager *manager.StorageManager, storageLockManager storage.LockManager, opts ConveyorOptions) *ConveyorWithRetryWrapper
func (*ConveyorWithRetryWrapper) Terminate ¶
func (wrapper *ConveyorWithRetryWrapper) Terminate() error
func (*ConveyorWithRetryWrapper) WithRetryBlock ¶
type Image ¶
type Image struct {
// contains filtered or unexported fields
}
func (*Image) FetchBaseImage ¶
func (*Image) GetBaseImage ¶
func (i *Image) GetBaseImage() *container_runtime.StageImage
func (*Image) GetContentSignature ¶
func (*Image) GetImageInfoGetter ¶ added in v1.2.0
func (i *Image) GetImageInfoGetter() *image.InfoGetter
func (*Image) GetLastNonEmptyStage ¶
func (*Image) GetLogName ¶
func (*Image) GetStageID ¶ added in v1.2.0
func (*Image) LogDetailedName ¶
func (*Image) LogProcessStyle ¶
func (*Image) LogTagStyle ¶
func (*Image) SetContentSignature ¶
func (*Image) SetLastNonEmptyStage ¶
func (*Image) SetupBaseImage ¶
type IntrospectOptions ¶
type IntrospectOptions struct {
Targets []IntrospectTarget
}
func (*IntrospectOptions) ImageStageShouldBeIntrospected ¶
func (opts *IntrospectOptions) ImageStageShouldBeIntrospected(imageName, stageName string) bool
type IntrospectTarget ¶
type Phase ¶
type Phase interface { Name() string BeforeImages(ctx context.Context) error AfterImages(ctx context.Context) error BeforeImageStages(ctx context.Context, img *Image) error OnImageStage(ctx context.Context, img *Image, stg stage.Interface) error AfterImageStages(ctx context.Context, img *Image) error ImageProcessingShouldBeStopped(ctx context.Context, img *Image) bool Clone() Phase }
type Report ¶
type Report struct {
Images map[string]ReportImageRecord
}
type ReportFormat ¶ added in v1.2.0
type ReportFormat string
const (
ReportJSON ReportFormat = "json"
)
type ReportImageRecord ¶ added in v1.2.0
type StagesIterator ¶
type StagesIterator struct { Conveyor *Conveyor PrevStage stage.Interface PrevNonEmptyStage stage.Interface PrevBuiltStage stage.Interface PrevNonEmptyStageImageSize int64 }
func NewStagesIterator ¶
func NewStagesIterator(conveyor *Conveyor) *StagesIterator
func (*StagesIterator) GetPrevBuiltImage ¶
func (iterator *StagesIterator) GetPrevBuiltImage(img *Image, stg stage.Interface) container_runtime.ImageInterface
func (*StagesIterator) GetPrevImage ¶
func (iterator *StagesIterator) GetPrevImage(img *Image, stg stage.Interface) container_runtime.ImageInterface
Source Files ¶
Click to show internal directories.
Click to hide internal directories.