Enrich logs, traces, events, and metrics with pod labels & annotations
groundcover allows you to add custom labels and annotations from Kubernetes pods and Docker containers to the metrics, traces, logs, and events generated by those pods or containers.
Specifying what to collect
To apply custom labels and annotations collection, you need to update your groundcover deployment values.yaml file.
The global.labelEnrichment configuration allows you to control exactly which labels and annotations are attached to each signal type (metrics, logs, traces, events).
To collect specific pod labels per signal type:
global:
labelEnrichment:
pods:
labels:
collectAll: false
metrics: ["app", "team"]
logs: ["app"]
traces: ["app", "team", "version"]
events: ["app", "team", "version", "tier"]
annotations:
collectAll: false
metrics: ["prometheus.io/port"]
logs: ["owner"]
traces: ["owner"]
events: ["owner", "oncall"]To collect all pod labels and/or annotations for all signals:
When collectAll is true, per-signal lists (metrics, logs, traces, events) are ignored.
Prefixes
We prefix the labels/annotations with the following (according to pod/docker):
k8s.pod.labelk8s.pod.annotationdocker.container.labeldocker.container.annotation

Searching labels and annotations
Once you've setup the configuration to the sensor, you will be able to view and search for specific labels and annotations like any other attribute.
For example, to search for traces, logs, or events that have the label app.kubernetes.io/part-of = groundcover you can do the following search:
k8s.pod.label.app.kubernetes.io/part-of:groundcover in the search bar.

Last updated
