journal hostname label

This commit is contained in:
Arne Teuke
2025-03-11 15:58:36 +01:00
parent a05dc843b6
commit 654989ce7c

View File

@@ -44,6 +44,11 @@ loki.source.file "system_logs" {
loki.relabel "add_labels" { loki.relabel "add_labels" {
forward_to = [loki.write.loki.receiver] forward_to = [loki.write.loki.receiver]
rule {
action = "replace"
source_labels = ["__hostname"]
target_label = "hostname"
}
rule { rule {
action = "replace" action = "replace"
target_label = "job" target_label = "job"