Documentation
¶
Index ¶
- Constants
- func Build(ctx context.Context, nodes []builder.Node, opt map[string]Options, ...) (resp map[string]*client.SolveResponse, err error)
- func BuildWithResultHandler(ctx context.Context, nodes []builder.Node, opt map[string]Options, ...) (resp map[string]*client.SolveResponse, err error)
- func Dial(ctx context.Context, nodes []builder.Node, pw progress.Writer, ...) (net.Conn, error)
- func IsRemoteURL(c string) bool
- func ReadSourcePolicy() (*spb.Policy, error)
- type Container
- type Inputs
- type NamedContext
- type Options
- type PrintFunc
- type ResultHandle
Constants ¶
View Source
const DockerfileLabel = "com.docker.image.source.entrypoint"
Variables ¶
This section is empty.
Functions ¶
func BuildWithResultHandler ¶ added in v0.9.0
func IsRemoteURL ¶ added in v0.11.0
func ReadSourcePolicy ¶ added in v0.11.0
ReadSourcePolicy reads a source policy from a file. The file path is taken from EXPERIMENTAL_BUILDKIT_SOURCE_POLICY env var. if the env var is not set, this `returns nil, nil`
Types ¶
type Container ¶ added in v0.11.0
type Container struct {
// contains filtered or unexported fields
}
func NewContainer ¶ added in v0.11.0
func NewContainer(ctx context.Context, resultCtx *ResultHandle, cfg *controllerapi.InvokeConfig) (*Container, error)
func (*Container) Exec ¶ added in v0.11.0
func (c *Container) Exec(ctx context.Context, cfg *controllerapi.InvokeConfig, stdin io.ReadCloser, stdout io.WriteCloser, stderr io.WriteCloser) error
func (*Container) IsUnavailable ¶ added in v0.11.0
type NamedContext ¶ added in v0.8.0
type Options ¶
type Options struct { Inputs Inputs Ref string Allow []entitlements.Entitlement Attests map[string]*string BuildArgs map[string]string CacheFrom []client.CacheOptionsEntry CacheTo []client.CacheOptionsEntry CgroupParent string Exports []client.ExportEntry ExtraHosts []string Labels map[string]string NetworkMode string NoCache bool NoCacheFilter []string Platforms []specs.Platform Pull bool ShmSize opts.MemBytes Tags []string Target string Ulimits *opts.UlimitOpt Session []session.Attachable Linked bool // Linked marks this target as exclusively linked (not requested by the user). PrintFunc *PrintFunc ProvenanceResponseMode confutil.MetadataProvenanceMode SourcePolicy *spb.Policy GroupRef string }
type ResultHandle ¶ added in v0.11.0
type ResultHandle struct {
// contains filtered or unexported fields
}
ResultHandle is a build result with the client that built it.
func NewResultHandle ¶ added in v0.11.0
func NewResultHandle(ctx context.Context, cc *client.Client, opt client.SolveOpt, product string, buildFunc gateway.BuildFunc, ch chan *client.SolveStatus) (*ResultHandle, *client.SolveResponse, error)
NewResultHandle makes a call to client.Build, additionally returning a opaque ResultHandle alongside the standard response and error.
This ResultHandle can be used to execute additional build steps in the same context as the build occurred, which can allow easy debugging of build failures and successes.
If the returned ResultHandle is not nil, the caller must call Done() on it.
func (*ResultHandle) Done ¶ added in v0.11.0
func (r *ResultHandle) Done()
Click to show internal directories.
Click to hide internal directories.