Documentation ¶
Overview ¶
Package runner contains a utility to run Docker containers
Create a RunHelper with NewRunHelper and then create new run instances with New()
Index ¶
- type RunHelper
- type Runner
- func (h *Runner) Bind(binds ...string) *Runner
- func (h *Runner) Command(cmd ...string) *Runner
- func (h *Runner) Copy(contents map[string][]byte) *Runner
- func (h *Runner) Create() (string, error)
- func (h *Runner) DNS(address ...string) *Runner
- func (h *Runner) DiscardContainer() *Runner
- func (h *Runner) Entrypoint(cmd ...string) *Runner
- func (h *Runner) Env(env ...string) *Runner
- func (h *Runner) HostNetwork() *Runner
- func (h *Runner) HostPid() *Runner
- func (h *Runner) Image(image string) *Runner
- func (h *Runner) Name(name string) *Runner
- func (h *Runner) Output() (string, string, int, error)
- func (h *Runner) PortForward(local, remote int) *Runner
- func (h *Runner) Privileged() *Runner
- func (h *Runner) Run() (int, error)
- func (h *Runner) Start() (string, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RunHelper ¶
type RunHelper struct {
// contains filtered or unexported fields
}
func NewRunHelper ¶
func NewRunHelper(client *docker.Client, dockerHelper *dockerhelper.Helper) *RunHelper
type Runner ¶
type Runner struct {
// contains filtered or unexported fields
}
Runner is a helper to run new containers on Docker
func (*Runner) DiscardContainer ¶
DiscardContainer if true will cause the container to be removed when done executing. Will be ignored in the case of Start
func (*Runner) Entrypoint ¶
Entrypoint sets the entrypoint to use when running
func (*Runner) HostNetwork ¶
HostNetwork tells Docker to run using the host's Network namespace
func (*Runner) PortForward ¶
func (*Runner) Privileged ¶
Privileged tells Docker to run the container as privileged
Click to show internal directories.
Click to hide internal directories.