Documentation ¶
Index ¶
- Constants
- type Container
- type ContainerCreateResponse
- type ContainerListOptions
- type ContainerState
- type ContainerStatus
- type Driver
- type ExecResult
- type ImageInspect
- type ImageListOptions
- type ImagePullOptions
- type ImageSummary
- type InspectContainerData
- type MountPoint
- type MountPropagation
- type MountType
- type NetworkCreateOptions
- type NetworkCreateResponse
- type NetworkListOptions
- type NetworkResource
- type Port
Constants ¶
View Source
const ( // defaultTimeout is the default timeout of short running docker operations. // Value is slightly offset from 2 minutes to make timeouts due to this // constant recognizable. DefaultTimeout = 2*time.Minute - 1*time.Second // defaultShmSize is the default ShmSize to use (in bytes) if not specified. DefaultShmSize = int64(1024 * 1024 * 64) // defaultImagePullingProgressReportInterval is the default interval of image pulling progress reporting. DefaultImagePullingProgressReportInterval = 10 * time.Second )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ContainerCreateResponse ¶
type ContainerListOptions ¶
type ContainerListOptions struct {
All bool
}
type ContainerState ¶
type ContainerStatus ¶
type ContainerStatus int
type Driver ¶
type Driver interface { New() error ImageInspect(id string) (*ImageInspect, error) ImagesList(options ImageListOptions) ([]ImageSummary, error) ImagesPull(refStr string, options ImagePullOptions) ([]string, error) ContainerCreate(image string) (ContainerCreateResponse, error) ContainerStart(id string) error ContainerWait(id string, state string, timeout time.Duration, interval time.Duration) error ContainerList(options ContainerListOptions) ([]Container, error) ContainerInspect(id string) (*InspectContainerData, error) ContainerStop(id string) error ContainerRemove(id string) error ContainerExec(id string, cmd []string) (ExecResult, error) NetworkCreate(name string, options NetworkCreateOptions) (NetworkCreateResponse, error) NetworkInspect(id string) (NetworkResource, error) NetworkRemove(id string) error NetworkConnect(id string, container string, aliases []string) error NetworkDisconnect(id string, container string, force bool) error }
type ExecResult ¶
func (*ExecResult) Stderr ¶
func (res *ExecResult) Stderr() string
func (*ExecResult) Stdout ¶
func (res *ExecResult) Stdout() string
type ImageInspect ¶
type ImageInspect struct { ID string `json:"Id"` Created int64 `json:"Created"` RepoTags []string `json:",omitempty"` Size int64 `json:"Size"` }
TODO: add Config
type ImageListOptions ¶
type ImageListOptions struct {
All bool
}
type ImagePullOptions ¶
type ImagePullOptions struct {
All bool
}
type ImageSummary ¶
type ImageSummary struct { ID string `json:"Id"` Created int64 `json:"Created"` Labels map[string]string `json:"Labels"` RepoTags []string `json:",omitempty"` RepoDigests []string `json:",omitempty"` Size int64 `json:"Size"` }
TODO: podman Image has container config, where should this come from
type InspectContainerData ¶
type InspectContainerData struct { // Base ID string `json:"Id"` Created time.Time `json:"Created"` Path string `json:"Path"` Args []string `json:"Args"` State *ContainerState `json:"State"` Image string `json:"Image"` ImageName string `json:"ImageName"` Name string `json:"Name"` Mounts []MountPoint }
NOTE: ContainerJSONBase for docker
InspectContainerData for podman
type MountPoint ¶
type MountPropagation ¶
type MountPropagation string
const ( PropagationRPrivate MountPropagation = "rprivate" PropagationPrivate MountPropagation = "private" )
TODO all propagation consts
type NetworkCreateOptions ¶
type NetworkCreateResponse ¶
type NetworkListOptions ¶
type NetworkListOptions struct {
All bool
}
type NetworkResource ¶
type NetworkResource struct {
Name string
}
Click to show internal directories.
Click to hide internal directories.