Documentation
¶
Index ¶
- func GetBinary() string
- func InitClient() error
- func PullImage(ref string) error
- func StartContainer(ref, name string, env []string, replace bool) error
- func StopContainer(name string) error
- type Client
- type Container
- type Image
- type Name
- type NameList
- type Params
- type PortList
- type Ref
- type Runtime
- type RuntimeBinary
- type RuntimeVersion
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitClient ¶
func InitClient() error
func StopContainer ¶
Types ¶
type Container ¶
func GetContainers ¶
type Runtime ¶
type Runtime interface {
Binary() string
Version(context.Context) (RuntimeVersion, error)
Images(context.Context, Ref) ([]Image, error)
Containers(context.Context, Name) ([]Container, error)
Run(context.Context, Ref, Params) error
Remove(context.Context, Name) error
Pull(context.Context, Ref) error
}
type RuntimeBinary ¶
type RuntimeBinary string
const ( RuntimeBinaryNone RuntimeBinary = "none" RuntimeBinaryNerdctl RuntimeBinary = "nerdctl" RuntimeBinaryPodman RuntimeBinary = "podman" RuntimeBinaryDocker RuntimeBinary = "docker" )
type RuntimeVersion ¶
type RuntimeVersion struct {
Name string
Client struct {
Version string
APIVersion string
}
Server struct {
Version string
APIVersion string
MinAPIVersion string
}
}
func GetVersion ¶
func GetVersion() (RuntimeVersion, error)
func (RuntimeVersion) String ¶
func (r RuntimeVersion) String() string
Click to show internal directories.
Click to hide internal directories.