builder

package
v0.4.3 Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2022 License: Apache-2.0 Imports: 19 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const DefaultDockerfileName = "Dockerfile"

DefaultDockerfileName is the default name of a Dockerfile

Variables

This section is empty.

Functions

func CreateTar

func CreateTar(contextDirectory, dockerfile string) (io.ReadCloser, error)

CreateTar create a build context tar for the specified project and service name.

Types

type Builder

type Builder interface {
	Build(imageName string) error
}

Builder defines methods to provide a docker builder. This makes libcompose not tied up to the docker daemon builder.

type DaemonBuilder

type DaemonBuilder struct {
	Client           client.ImageAPIClient
	ContextDirectory string
	Dockerfile       string
	AuthConfigs      map[string]types.AuthConfig
	NoCache          bool
	ForceRemove      bool
	Pull             bool
	BuildArgs        map[string]*string
	CacheFrom        []string
	Labels           map[string]*string
	Network          string
	Target           string
	LoggerFactory    logger.Factory
}

DaemonBuilder is the daemon "docker build" Builder implementation.

func (*DaemonBuilder) Build

func (d *DaemonBuilder) Build(ctx context.Context, imageName string) error

Build implements Builder. It consumes the docker build API endpoint and sends a tar of the specified service build context.

Jump to

Keyboard shortcuts

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