Documentation
¶
Overview ¶
Package types contains types used for managing the containers. They are put in separate package to avoid cyclic dependencies while importing.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ContainerConfig ¶
type ContainerConfig struct { Name string `json:"name"` Image string `json:"image"` Args []string `json:"args,omitempty"` Entrypoint []string `json:"entrypoint,omitempty"` Ports []PortMap `json:"ports,omitempty"` Mounts []Mount `json:"mounts,omitempty"` Privileged bool `json:"privileged,omitempty"` NetworkMode string `json:"networkMode,omitempty"` PidMode string `json:"pidMode,omitempty"` IpcMode string `json:"ipcMode,omitempty"` User string `json:"user,omitempty"` Group string `json:"group,omitempty"` }
ContainerConfig stores runtime-agnostic information how to run the container
type ContainerStatus ¶
type ContainerStatus struct { ID string `json:"id,omitempty"` Status string `json:"status,omitempty"` }
ContainerStatus stores status information received from the runtime TODO this should cover all fields which are defined in ContainerConfig, so we can read and compare if actual configuration matches our expectations.
func (*ContainerStatus) Exists ¶ added in v0.2.0
func (s *ContainerStatus) Exists() bool
Exists controls, how container existence is determined based on ContainerStatus. If state has no ID set, it means that container does not exist.
func (*ContainerStatus) Running ¶ added in v0.2.0
func (s *ContainerStatus) Running() bool
Running determines if container is running, based on ContainerStatus.
type File ¶
type File struct { Path string `json:"path"` Content string `json:"content"` Mode int64 `json:"mode"` User string `json:"uid"` Group string `json:"gid"` }
File describes file, which can be either copied to or from container.