Documentation ¶
Index ¶
Constants ¶
View Source
const ( PodNameLabel = "io.kubernetes.pod.name" PodNamespaceLabel = "io.kubernetes.pod.namespace" PodUIDLabel = "io.kubernetes.pod.uid" ContainerNameLabel = "io.kubernetes.container.name" ContainerTypeDockerLabel = "io.kubernetes.docker.type" ContainerTypeContainerdLabel = "io.cri-containerd.kind" ContainerTypeCrioAnnotation = "io.kubernetes.cri-o.ContainerType" )
These labels are injected by kubelet on container creation, we can use them to gather additional data in a k8s context
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ContainerEnricher ¶
type ContainerEnricher interface {
Get(ctx context.Context, containerId string) (ContainerMetadata, error)
}
func ContainerdEnricher ¶
func ContainerdEnricher(socket string) (ContainerEnricher, error)
func CrioEnricher ¶
func CrioEnricher(socket string) (ContainerEnricher, error)
func DockerEnricher ¶
func DockerEnricher(socket string) (ContainerEnricher, error)
type ContainerMetadata ¶
type ContainerMetadata struct { ContainerId string Name string Image string ImageDigest string Pod PodMetadata }
type RuntimeId ¶
type RuntimeId int
Represents the internal ID of a container runtime
func FromString ¶
type Sockets ¶
type Sockets struct {
// contains filtered or unexported fields
}
Sockets represent existing container runtime connections
func Autodiscover ¶
check default paths for all supported container runtimes and aggregate them
func (*Sockets) Register ¶
Register attempts to associate a file path with a container runtime, if the path doesn't exist registration will fail
Click to show internal directories.
Click to hide internal directories.