Documentation ¶
Overview ¶
Package containerd is the API implementation on containerd.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Container ¶ added in v1.2.0
type Container struct { behaviour.Closer behaviour.FileSystem behaviour.Psutil behaviour.Container // contains filtered or unexported fields }
func (*Container) Runtime ¶ added in v1.2.0
func (c *Container) Runtime() *Containerd
type Containerd ¶
type Containerd struct { behaviour.Closer behaviour.Runtime behaviour.FileSystem // contains filtered or unexported fields }
Containerd is the connection established with a containerd runtime.
func (*Containerd) OpenContainerByID ¶ added in v1.2.0
func (d *Containerd) OpenContainerByID(id string) (api.Container, error)
func (*Containerd) OpenImageByID ¶
func (d *Containerd) OpenImageByID(id string) (api.Image, error)
func (*Containerd) UniqueDesc ¶ added in v1.1.0
func (d *Containerd) UniqueDesc() string
UniqueDesc represents the containerd runtime's initialization arguments, which can be passed across process boundaries and initialize the same docker in another process.
type Image ¶
type Image struct { behaviour.Closer behaviour.Image behaviour.FileSystem // contains filtered or unexported fields }
Image represents a containerd image, which is guaranteed to be the result of docker.Docker.OpenImageByID.
func (*Image) Runtime ¶
func (i *Image) Runtime() *Containerd
type NewOption ¶ added in v1.1.0
type NewOption func(*newArgs)
NewOption is the option that can be used for initializing an containerd.Containerd object.
func WithConfigPath ¶ added in v1.1.0
WithConfigPath specifies the path of containerd's config file.
Specifying this argument is semantically equivalent to specifying flag "--config" or "-c" to containerd, and its default search path is "/etc/containerd/config.toml".
Both containerd and veinmind will render "/etc/containerd/config.toml" file as dispensible and fallback to use internal default config if unspecified. But once the argument is specified, it is no longer dispensible and error will be raised if the config is not found.
func WithRootDir ¶ added in v1.1.0
WithRootDir specifies the path of containerd's root directory.
Specifying this argument is semantically equivalent to specifying flag "--root" to containerd, and its default value is "/var/lib/containerd".
func WithUniqueDesc ¶ added in v1.1.0
WithUniqueDesc specifies the unique descriptor of dockerd.
This argument must be result of containerd.(*Containerd).UniqueDesc() from another containerd.Containerd instance, potentially from another process. And the initialization might still fail if the API runtime context has not been set up properly.