prometheus operator v0.71.2

ScrapeConfig.spec.kubernetesSDConfigs.proxyConnectHeader.[key].spec.relabelings

RelabelConfigs defines how to rewrite the target's labels before scraping. Prometheus Operator automatically adds relabelings for a few standard Kubernetes fields. The original scrape job's name is available via the `__tmp_prometheus_job_name` label. More info: https://prometheus.io/docs/prometheus/latest/configuration/configuration/#relabel_config

7 fields
ScrapeConfig.spec.kubernetesSDConfigs.proxyConnectHeader.[key].spec.relabelings fields and descriptions
Field / TypeDescription
action
string

Action to perform based on the regex matching. `Uppercase` and `Lowercase` actions require Prometheus >= v2.36.0. `DropEqual` and `KeepEqual` actions require Prometheus >= v2.41.0. Default: "Replace"

  • enum: ["replace","Replace","keep","Keep","drop","Drop","hashmod","HashMod","labelmap","LabelMap","labeldrop","LabelDrop","labelkeep","LabelKeep","lowercase","Lowercase","uppercase","Uppercase","keepequal","KeepEqual","dropequal","DropEqual"]
  • default: "replace"
modulus
integer

Modulus to take of the hash of the source label values. Only applicable when the action is `HashMod`.

  • format: int64
regex
string

Regular expression against which the extracted value is matched.

replacement
string

Replacement value against which a Replace action is performed if the regular expression matches. Regex capture groups are available.

separator
string

Separator is the string between concatenated SourceLabels.

string[]

The source labels select values from existing labels. Their content is concatenated using the configured Separator and matched against the configured regular expression.

targetLabel
string

Label to which the resulting string is written in a replacement. It is mandatory for `Replace`, `HashMod`, `Lowercase`, `Uppercase`, `KeepEqual` and `DropEqual` actions. Regex capture groups are available.