instruction

package
v2.13.0 Latest Latest
Warning

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

Go to latest
Published: Nov 14, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EnvToSortedArr

func EnvToSortedArr(env map[string]string) (r []string)

Types

type Add

func NewAdd

func NewAdd(i *dockerfile.DockerfileStageInstruction[*instructions.AddCommand], dependencies []*config.Dependency, hasPrevStage bool, opts *stage.BaseStageOptions) *Add

func (*Add) GetDependencies

func (stg *Add) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

type Base

type Base[T dockerfile.InstructionDataInterface, BT container_backend.InstructionInterface] struct {
	*stage.BaseStage
	// contains filtered or unexported fields
}

func NewBase

func NewBase[T dockerfile.InstructionDataInterface, BT container_backend.InstructionInterface](instruction *dockerfile.DockerfileStageInstruction[T], backendInstruction BT, dependencies []*config.Dependency, hasPrevStage bool, opts *stage.BaseStageOptions) *Base[T, BT]

func (*Base[T, BT]) ExpandDependencies

func (stg *Base[T, BT]) ExpandDependencies(ctx context.Context, c stage.Conveyor, baseEnv map[string]string) error

func (*Base[T, BT]) ExpandInstruction

func (stg *Base[T, BT]) ExpandInstruction(_ stage.Conveyor, env map[string]string) error

func (*Base[T, BT]) GetExpandedEnv

func (stg *Base[T, BT]) GetExpandedEnv(c stage.Conveyor) map[string]string

func (*Base[T, BT]) HasPrevStage

func (stg *Base[T, BT]) HasPrevStage() bool

func (*Base[T, BT]) IsStapelStage

func (stg *Base[T, BT]) IsStapelStage() bool

func (*Base[T, BT]) PrepareImage

func (stg *Base[T, BT]) PrepareImage(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevBuiltImage, stageImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) error

func (*Base[T, BT]) UsesBuildContext

func (stg *Base[T, BT]) UsesBuildContext() bool

type Cmd

func NewCmd

func NewCmd(i *dockerfile.DockerfileStageInstruction[*instructions.CmdCommand], dependencies []*config.Dependency, hasPrevStage bool, opts *stage.BaseStageOptions) *Cmd

func (*Cmd) GetDependencies

func (stg *Cmd) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

type Copy

func NewCopy

func (*Copy) ExpandDependencies

func (stg *Copy) ExpandDependencies(ctx context.Context, c stage.Conveyor, baseEnv map[string]string) error

func (*Copy) ExpandInstruction

func (stg *Copy) ExpandInstruction(c stage.Conveyor, env map[string]string) error

func (*Copy) GetDependencies

func (stg *Copy) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

type Entrypoint

func NewEntrypoint

func NewEntrypoint(i *dockerfile.DockerfileStageInstruction[*instructions.EntrypointCommand], dependencies []*config.Dependency, hasPrevStage, entrypointResetCMD bool, opts *stage.BaseStageOptions) *Entrypoint

func (*Entrypoint) GetDependencies

func (stg *Entrypoint) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

type Env

func NewEnv

func NewEnv(i *dockerfile.DockerfileStageInstruction[*instructions.EnvCommand], dependencies []*config.Dependency, hasPrevStage bool, opts *stage.BaseStageOptions) *Env

func (*Env) GetDependencies

func (stg *Env) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

type Expose

func (*Expose) GetDependencies

func (stg *Expose) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

type From

type From struct {
	stage.BaseStage

	BaseImageReference  string
	BaseImageRepoDigest string
}

func NewFrom

func NewFrom(baseImageReference, baseImageRepoDigest string, opts *stage.BaseStageOptions) *From

func (*From) ExpandDependencies

func (stg *From) ExpandDependencies(ctx context.Context, c stage.Conveyor, baseEnv map[string]string) error

func (*From) GetDependencies

func (s *From) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

func (*From) HasPrevStage

func (stg *From) HasPrevStage() bool

func (*From) IsStapelStage

func (stg *From) IsStapelStage() bool

func (*From) PreRun

func (s *From) PreRun(ctx context.Context, _ stage.Conveyor) error

func (*From) PrepareImage

func (stg *From) PrepareImage(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevBuiltImage, stageImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) error

func (*From) UsesBuildContext

func (stg *From) UsesBuildContext() bool

type Healthcheck

func (*Healthcheck) GetDependencies

func (stg *Healthcheck) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

type InstructionExpander

type InstructionExpander interface {
	ExpandInstruction(c stage.Conveyor, env map[string]string) error
}

type Label

func (*Label) GetDependencies

func (stg *Label) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

type Maintainer

func (*Maintainer) GetDependencies

func (stg *Maintainer) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

type OnBuild

func (*OnBuild) GetDependencies

func (stg *OnBuild) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

type Run

func NewRun

func NewRun(i *dockerfile.DockerfileStageInstruction[*instructions.RunCommand], dependencies []*config.Dependency, hasPrevStage bool, opts *stage.BaseStageOptions) *Run

func (*Run) ExpandDependencies

func (stg *Run) ExpandDependencies(ctx context.Context, c stage.Conveyor, baseEnv map[string]string) error

func (*Run) ExpandInstruction

func (stg *Run) ExpandInstruction(c stage.Conveyor, env map[string]string) error

func (*Run) GetDependencies

func (stg *Run) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

type Shell

func (*Shell) GetDependencies

func (stg *Shell) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

type StopSignal

func (*StopSignal) GetDependencies

func (stg *StopSignal) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

type User

func NewUser

func (*User) GetDependencies

func (stg *User) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

type Volume

func (*Volume) GetDependencies

func (stg *Volume) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

type Workdir

func (*Workdir) GetDependencies

func (stg *Workdir) GetDependencies(ctx context.Context, c stage.Conveyor, cb container_backend.ContainerBackend, prevImage, prevBuiltImage *stage.StageImage, buildContextArchive container_backend.BuildContextArchiver) (string, error)

Jump to

Keyboard shortcuts

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