Documentation
¶
Index ¶
- func NewDocker(client *dockerclient.Client, opts ...dockerOption) *docker
- func WithContext(ctx context.Context) func(*docker)
- func WithHidePullOutput(hide bool) func(*docker)
- func WithLogger(logger logr.Logger) func(*docker)
- func WithVolumes(volumes []string) func(*docker)
- type Await
- type ContainerSpec
- type ContainerStatus
- type Event
- type EventType
- type Interface
- type Pod
- type PodSpec
- type PodStatus
- type PullImagePolicy
- type RestartPolicy
- type Result
- type Volume
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewDocker ¶
func NewDocker(client *dockerclient.Client, opts ...dockerOption) *docker
func WithContext ¶
func WithHidePullOutput ¶ added in v0.0.16
func WithHidePullOutput(hide bool) func(*docker)
func WithLogger ¶
func WithVolumes ¶ added in v0.0.16
func WithVolumes(volumes []string) func(*docker)
Types ¶
type ContainerSpec ¶
type ContainerSpec struct { Name string Args []string Command []string Image string ImagePullPolicy PullImagePolicy Stdin bool TTY bool Env []string User string PWD string RestartPolicy RestartPolicy }
func GetContainerSpecByName ¶
func GetContainerSpecByName(pod *Pod, name string) (ContainerSpec, error)
type ContainerStatus ¶
type ContainerStatus struct { ContainerID string ContainerIP string Name string Ready bool Started bool ExitCode int }
func GetContainerStatusByID ¶
func GetContainerStatusByID(pod *Pod, id string) (ContainerStatus, error)
func GetContainerStatusByName ¶
func GetContainerStatusByName(pod *Pod, name string) (ContainerStatus, error)
type PodSpec ¶
type PodSpec struct { Containers []ContainerSpec InitContainers []ContainerSpec Volumes []Volume }
type PodStatus ¶
type PodStatus struct { PodIP string Containers []ContainerStatus InitContainers []ContainerStatus }
type PullImagePolicy ¶
type PullImagePolicy string
var ( PullImagePolicyAlways PullImagePolicy = "Always" PullImagePolicyNever PullImagePolicy = "Never" PullImagePolicyMissing PullImagePolicy = "Missing" )
type RestartPolicy ¶
type RestartPolicy string
var ( RestartPolicyNever RestartPolicy = "Never" RestartPolicyOnFailure RestartPolicy = "OnFailure" RestartPolicyAlways RestartPolicy = "Always" )
Click to show internal directories.
Click to hide internal directories.