Documentation
¶
Index ¶
- type ConfigAdapter
- type ContainerManager
- func (c *ContainerManager) AttachLogger(ctx context.Context, containerID string, options container.AttachOptions) (types.HijackedResponse, error)
- func (c *ContainerManager) CopyToContainer(ctx context.Context, containerID string, dest string, content io.Reader, ...) error
- func (c *ContainerManager) CreateContainer(ctx context.Context, job config.JobConfig) (container.CreateResponse, error)
- func (c *ContainerManager) ListContainers(ctx context.Context, options container.ListOptions) ([]container.Summary, error)
- func (c *ContainerManager) RemoveContainer(ctx context.Context, containerID string, options container.RemoveOptions) error
- func (c *ContainerManager) StartContainer(ctx context.Context, containerID string, options container.StartOptions) error
- func (c *ContainerManager) StopContainer(ctx context.Context, containerID string, options container.StopOptions) error
- func (c *ContainerManager) WaitForContainer(ctx context.Context, containerID string, condition container.WaitCondition) (<-chan container.WaitResponse, <-chan error)
- type Executor
- type ImageManager
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 (c *ContainerManager) CreateContainer(ctx context.Context, job config.JobConfig) (container.CreateResponse, error)
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
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)
Click to show internal directories.
Click to hide internal directories.