Documentation ¶
Index ¶
- func CreateVolumeMount(vol string) (mount.Mount, error)
- type Container
- type Containers
- func (containerArray *Containers) DockerStartContainer(ctx context.Context, cli *client.Client) error
- func (containerArray *Containers) GetEnv(configDir string) error
- func (containerArray *Containers) OverrideEnv(envOverrides []string) error
- func (containerArray *Containers) SetHostDevice(device string)
- func (containerArray *Containers) SetHostNetwork()
- func (containerArray *Containers) SetInputSrc() error
- func (containerArray *Containers) SetPrivileged()
- func (containerArray *Containers) SetTargetDevice() error
- func (containerArray *Containers) SetVolumes(volumes []string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Container ¶
type Container struct { Name string `yaml:"Name"` DockerImage string `yaml:"DockerImage"` EnvironmentVariableFiles string `yaml:"EnvironmentVariableFiles"` Envs []string `yaml:"Envs"` Volumes []string `yaml:"Volumes"` Entrypoint string `yaml:"Entrypoint"` HostConfig container.HostConfig `yaml:"HostConfig"` }
type Containers ¶
type Containers struct { Containers []Container `yaml:"Containers"` InputSrc string `yaml:"InputSrc"` TargetDevice string `yaml:"TargetDevice"` }
func GetYamlConfig ¶
func GetYamlConfig(configDir string) (Containers, error)
func (*Containers) DockerStartContainer ¶
func (containerArray *Containers) DockerStartContainer(ctx context.Context, cli *client.Client) error
Create and start the Docker container
func (*Containers) GetEnv ¶
func (containerArray *Containers) GetEnv(configDir string) error
func (*Containers) OverrideEnv ¶
func (containerArray *Containers) OverrideEnv(envOverrides []string) error
func (*Containers) SetHostDevice ¶
func (containerArray *Containers) SetHostDevice(device string)
Setup the device mount
func (*Containers) SetHostNetwork ¶
func (containerArray *Containers) SetHostNetwork()
Set container to use host network
func (*Containers) SetInputSrc ¶
func (containerArray *Containers) SetInputSrc() error
Setup devices and other mounts based on the inputsrc
func (*Containers) SetPrivileged ¶
func (containerArray *Containers) SetPrivileged()
Set the container to privileged mode
func (*Containers) SetTargetDevice ¶
func (containerArray *Containers) SetTargetDevice() error
Setup device mounts and ENV based on the targe device input
func (*Containers) SetVolumes ¶
func (containerArray *Containers) SetVolumes(volumes []string) error
Setup volume mounts for the countainer
Click to show internal directories.
Click to hide internal directories.