daemonbuilder

package
v1.4.2-0...-b72a431 Latest Latest
Warning

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

Go to latest
Published: Oct 27, 2015 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DetectContextFromRemoteURL

func DetectContextFromRemoteURL(r io.ReadCloser, remoteURL string, progressReader *progressreader.Config) (context builder.ModifiableContext, dockerfileName string, err error)

DetectContextFromRemoteURL returns a context and in certain cases the name of the dockerfile to be used irrespective of user input. progressReader is only used if remoteURL is actually a URL (not empty, and not a Git endpoint).

Types

type Docker

type Docker struct {
	Daemon      *daemon.Daemon
	OutOld      io.Writer
	AuthConfigs map[string]cliconfig.AuthConfig
	Archiver    *archive.Archiver
}

Docker implements builder.Docker for the docker Daemon object.

func (Docker) Commit

Commit creates a new Docker image from an existing Docker container.

func (Docker) Container

func (d Docker) Container(id string) (*daemon.Container, error)

Container looks up a Docker container referenced by `id`.

func (Docker) Copy

func (d Docker) Copy(c *daemon.Container, destPath string, src builder.FileInfo, decompress bool) error

Copy copies/extracts a source FileInfo to a destination path inside a container specified by a container object. TODO: make sure callers don't unnecessarily convert destPath with filepath.FromSlash (Copy does it already). Copy should take in abstract paths (with slashes) and the implementation should convert it to OS-specific paths.

func (Docker) Create

func (d Docker) Create(cfg *runconfig.Config, hostCfg *runconfig.HostConfig) (*daemon.Container, []string, error)

Create creates a new Docker container and returns potential warnings

func (Docker) GetCachedImage

func (d Docker) GetCachedImage(imgID string, cfg *runconfig.Config) (string, error)

GetCachedImage returns a reference to a cached image whose parent equals `parent` and runconfig equals `cfg`. A cache miss is expected to return an empty ID and a nil error.

func (Docker) LookupImage

func (d Docker) LookupImage(name string) (*image.Image, error)

LookupImage looks up a Docker image referenced by `name`.

func (Docker) Pull

func (d Docker) Pull(name string) (*image.Image, error)

Pull tells Docker to pull image referenced by `name`.

func (Docker) Release

func (d Docker) Release(sessionID string, activeImages []string)

Release releases a list of images that were retained for the time of a build.

func (Docker) Remove

func (d Docker) Remove(id string, cfg *daemon.ContainerRmConfig) error

Remove removes a container specified by `id`.

func (Docker) Retain

func (d Docker) Retain(sessionID, imgID string)

Retain retains an image avoiding it to be removed or overwritten until a corresponding Release() call.

Jump to

Keyboard shortcuts

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