Documentation ¶
Index ¶
- func CRIContainerToContainerData(runtimeName types.RuntimeName, container CRIContainer) *runtimeclient.ContainerData
- type CRIClient
- func (c *CRIClient) Close() error
- func (c *CRIClient) GetContainer(containerID string) (*runtimeclient.ContainerData, error)
- func (c *CRIClient) GetContainerDetails(containerID string) (*runtimeclient.ContainerDetailsData, error)
- func (c *CRIClient) GetContainers() ([]*runtimeclient.ContainerData, error)
- type CRIContainer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CRIContainerToContainerData ¶
func CRIContainerToContainerData(runtimeName types.RuntimeName, container CRIContainer) *runtimeclient.ContainerData
Types ¶
type CRIClient ¶
type CRIClient struct { Name types.RuntimeName SocketPath string ConnTimeout time.Duration // contains filtered or unexported fields }
CRIClient implements the ContainerRuntimeClient interface using the CRI plugin interface to communicate with the different container runtimes.
func NewCRIClient ¶
func (*CRIClient) GetContainer ¶
func (c *CRIClient) GetContainer(containerID string) (*runtimeclient.ContainerData, error)
func (*CRIClient) GetContainerDetails ¶
func (c *CRIClient) GetContainerDetails(containerID string) (*runtimeclient.ContainerDetailsData, error)
func (*CRIClient) GetContainers ¶
func (c *CRIClient) GetContainers() ([]*runtimeclient.ContainerData, error)
type CRIContainer ¶ added in v0.19.0
type CRIContainer interface { GetId() string GetState() runtime.ContainerState GetMetadata() *runtime.ContainerMetadata GetLabels() map[string]string GetImage() *runtime.ImageSpec GetImageRef() string }
CRIContainer is an interface that contains the methods required to get the information of a container from the responses of the CRI. In particular, from runtime.ContainerStatus and runtime.Container.
Click to show internal directories.
Click to hide internal directories.