Documentation ¶
Index ¶
- func CheckDaemon() error
- func ForceStop(ctx context.Context, name string, client *client.Client) error
- func NewClient() (*client.Client, error)
- type ComposeService
- type Container
- func (c *Container) HostPort() string
- func (c *Container) Logs(ctx context.Context, client *client.Client, since time.Time, follow bool) (io.ReadCloser, error)
- func (c *Container) LookupHostConfig(ctx context.Context, client *client.Client) (*Container, error)
- func (c *Container) Remove(ctx context.Context, client *client.Client) error
- func (c *Container) Start(ctx context.Context, client *client.Client, restart bool) (*Container, error)
- type ContainerOption
- type HostOption
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckDaemon ¶ added in v1.1.0
func CheckDaemon() error
Types ¶
type ComposeService ¶ added in v1.2.0
type Container ¶
type Container struct { ID string Name string Image string Online bool CreateContainerOptions []ContainerOption CreateHostOptions []HostOption // contains filtered or unexported fields }
func (*Container) LookupHostConfig ¶
type ContainerOption ¶
func WithEntrypoint ¶
func WithEntrypoint(entrypoint []string) ContainerOption
func WithEnv ¶
func WithEnv(env []string) ContainerOption
func WithErrorLoggingLevel ¶
func WithErrorLoggingLevel() ContainerOption
func WithImage ¶
func WithImage(image string) ContainerOption
func WithPort ¶
func WithPort(port nat.Port) ContainerOption
type HostOption ¶
type HostOption func(*container.HostConfig)
func WithExtraHost ¶
func WithExtraHost() HostOption
func WithHostPortBinding ¶
func WithHostPortBinding(containerPort nat.Port) HostOption
func WithVolumeBind ¶
func WithVolumeBind(bind string) HostOption
Click to show internal directories.
Click to hide internal directories.