cadvisor: Index | Files | Directories

package crio

import ""

Handler for CRI-O containers.


Package Files

client.go factory.go handler.go plugin.go


const CrioNamespace = "crio"

The namespace under which crio aliases are unique.

const (
    CrioSocket = "/var/run/crio/crio.sock"

func ContainerNameToCrioId Uses

func ContainerNameToCrioId(name string) string

Returns the CRIO ID from the full container name.

func NewPlugin Uses

func NewPlugin() container.Plugin

NewPlugin returns an implementation of container.Plugin suitable for passing to container.RegisterPlugin()

func Register Uses

func Register(factory info.MachineInfoFactory, fsInfo fs.FsInfo, includedMetrics container.MetricSet) error

Register root container before running this function!

type ContainerInfo Uses

type ContainerInfo struct {
    Name        string            `json:"name"`
    Pid         int               `json:"pid"`
    Image       string            `json:"image"`
    CreatedTime int64             `json:"created_time"`
    Labels      map[string]string `json:"labels"`
    Annotations map[string]string `json:"annotations"`
    LogPath     string            `json:"log_path"`
    Root        string            `json:"root"`
    IP          string            `json:"ip_address"`
    IPs         []string          `json:"ip_addresses"`

ContainerInfo represents a given container information

type CrioClient Uses

type CrioClient interface {
    Info() (Info, error)
    ContainerInfo(string) (*ContainerInfo, error)

func Client Uses

func Client() (CrioClient, error)

Client returns a new configured CRI-O client

type Info Uses

type Info struct {
    StorageDriver string `json:"storage_driver"`
    StorageRoot   string `json:"storage_root"`

Info represents CRI-O information as sent by the CRI-O server


installThe install package registers crio.NewPlugin() as the "crio" container provider when imported

Package crio imports 21 packages (graph) and is imported by 28 packages. Updated 2020-06-05. Refresh now. Tools for package owners.