buildkit

package
v0.0.0-...-7280f38 Latest Latest
Warning

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

Go to latest
Published: Sep 5, 2020 License: Apache-2.0 Imports: 68 Imported by: 0

Documentation

Index

Constants

View Source
const (
	KeyGitURL         = "git-url"
	KeyGitRef         = "git-ref"
	KeyLocalDir       = "local-dir"
	KeySubdir         = "subdir"
	KeySourcerName    = "sourcer-name"
	KeyRunType        = "runtype"
	KeyLocalOverrides = "local-overrides"
	KeyImageRef       = "image-ref"
	KeyBuildID        = "build-id"
)
View Source
const (
	// TODO don't hardcode
	Root = "/var/lib/buildkitd"
)

Variables

This section is empty.

Functions

func BincastleBuild

func BincastleBuild(ctx context.Context, args BincastleArgs) error

func Buildkitd

func Buildkitd(mountBackend ctr.MountBackend) (func(context.Context) error, error)

func ExecNameToID

func ExecNameToID(execName string) string

func IDToExecName

func IDToExecName(id string) (string, error)

func RuncWorkers

func RuncWorkers(
	root string, gcKeepStorage int64, mountBackend ctr.MountBackend, sm *session.Manager,
) ([]worker.Worker, func() error, *workerBackend, error)

Types

type BincastleArgs

type BincastleArgs struct {
	SourceGitURL   string
	SourceGitRef   string
	SourceLocalDir string
	SourceSubdir   string
	SourcerName    string
	LocalOverrides []string

	LLB *llb.Definition

	ImportCacheRef   string
	ExportCacheRef   string
	ExportLocalDir   string
	ExportImageRef   string
	SSHAgentSockPath string

	BincastleSockPath string
	Verbose           bool
}

type BincastleFrontend

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

TODO would be nice for this to eventually be implemented via Gateway, but need way to do the careful management of mutable refs required for persistence of exec state

func (*BincastleFrontend) Solve

func (f *BincastleFrontend) Solve(ctx context.Context, llbBridge frontend.FrontendLLBBridge, opt map[string]string, inputs map[string]*pb.Definition, sid string) (*frontend.Result, error)

type DefinitionSourcer

type DefinitionSourcer interface {
	DefinitionSource(llbsrc AsSpec, cmdPath string) (*Graph, *executor.Meta, error)
}

type Executor

type Executor interface {
	executor.Executor
	Shutdown()
}

type RunType

type RunType string

TODO this is pretty dumb, it should be removed once there's an official merge-op (which will allow the frontend to just consistently return a merge-op as its only result instead of choosing what to do based on which RunType is provided)

const (
	PreBuild    RunType = "prebuild"
	Exec        RunType = "exec"
	LocalExport RunType = "local-export"
	ImageExport RunType = "image-export"
	CacheExport RunType = "cache-export"
)

Jump to

Keyboard shortcuts

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