add hostname label

This commit is contained in:
Arne Teuke
2025-03-11 11:53:38 +01:00
parent f0ba7e993f
commit 94a1253d6f

View File

@@ -33,6 +33,11 @@ loki.relabel "add_labels" {
source_labels = ["__host__"] // Internal hostname from constants.hostname
target_label = "hostname"
}
rule {
action = "replace"
target_label = "hostname"
replacement = "fqdn"
}
rule {
action = "replace"
target_label = "job"