builder

package
v0.0.0-...-dea2efb Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2024 License: Apache-2.0 Imports: 23 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var WriteTime = time.Time{}

Functions

func Build

func Build(ctx context.Context, b BuildSpec) error

func ByteCount

func ByteCount(b int64) string

func CreateProgress

func CreateProgress(name string) chan v1.Update

func Experiment

func Experiment()

func IsExecOwner

func IsExecOwner(mode os.FileMode) bool

func WarmBase

func WarmBase(ctx context.Context, architectures []string, baseImages ...string)

func WriteArchiveFromFS

func WriteArchiveFromFS(base string, fsys fs.FS, out io.Writer, sourceDateEpoch time.Time) error

Writes a raw TAR archive to out, given an fs.FS.

func WriteArchiveFromFiles

func WriteArchiveFromFiles(base string, files map[string]string, out io.Writer) error

Types

type Args

type Args struct {
	// Name is optional, for logging
	Name string

	// Image architecture. Required only when multiple images present
	Arch string

	Env        map[string]string
	Labels     map[string]string
	User       string
	WorkDir    string
	Entrypoint []string
	Cmd        []string

	// Base image to use
	Base string

	// Files contains all files, mapping destination path -> source path
	Files map[string]string
	// FilesBase is the base path for absolute paths in Files
	FilesBase string
}

type BuildSpec

type BuildSpec struct {
	// Name is optional, for logging
	Name  string
	Dests []string
	Args  []Args
}

Jump to

Keyboard shortcuts

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