docker

package
v0.0.22 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2026 License: MIT Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ConfigAdapter

type ConfigAdapter interface {
	ToContainerConfig(job config.JobConfig) *container.Config
	ToHostConfig(job config.JobConfig) *container.HostConfig
	ToImageHostConfig(image string) string
}

func NewConfigAdapter

func NewConfigAdapter(cfg *config.Config) ConfigAdapter

type ContainerManager

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

func NewContainerManager

func NewContainerManager(cli *client.Client, adapter ConfigAdapter) *ContainerManager

func (*ContainerManager) AttachLogger

func (c *ContainerManager) AttachLogger(ctx context.Context, containerID string, options container.AttachOptions) (types.HijackedResponse, error)

func (*ContainerManager) CopyToContainer

func (c *ContainerManager) CopyToContainer(ctx context.Context, containerID string, dest string, content io.Reader, options container.CopyToContainerOptions) error

func (*ContainerManager) CreateContainer

func (*ContainerManager) ListContainers added in v0.0.13

func (c *ContainerManager) ListContainers(ctx context.Context, options container.ListOptions) ([]container.Summary, error)

func (*ContainerManager) RemoveContainer

func (c *ContainerManager) RemoveContainer(ctx context.Context, containerID string, options container.RemoveOptions) error

func (*ContainerManager) StartContainer

func (c *ContainerManager) StartContainer(ctx context.Context, containerID string, options container.StartOptions) error

func (*ContainerManager) StopContainer

func (c *ContainerManager) StopContainer(ctx context.Context, containerID string, options container.StopOptions) error

func (*ContainerManager) WaitForContainer

func (c *ContainerManager) WaitForContainer(ctx context.Context, containerID string, condition container.WaitCondition) (<-chan container.WaitResponse, <-chan error)

type Executor

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

func NewDockerExecutor

func NewDockerExecutor(client *client.Client, adapter ConfigAdapter) *Executor

func (*Executor) Cleanup

func (e *Executor) Cleanup(ctx context.Context) error

func (*Executor) Execute

func (e *Executor) Execute(ctx context.Context, job config.JobConfig) error

type ImageManager

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

func NewImageManager

func NewImageManager(cli *client.Client, adapter ConfigAdapter) *ImageManager

func (*ImageManager) PullImage

func (i *ImageManager) PullImage(ctx context.Context, image string, options image.PullOptions) (io.ReadCloser, error)

Jump to

Keyboard shortcuts

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