source hostname label
This commit is contained in:
@@ -50,12 +50,12 @@ loki.relabel "add_labels" {
|
||||
source_labels = ["hostname"]
|
||||
target_label = "hostname"
|
||||
}
|
||||
rule {
|
||||
source_labels = ["hostname_fallback"]
|
||||
target_label = "hostname"
|
||||
action = "replace"
|
||||
replacement = "${__label:hostname_fallback}" // Only if hostname is unset
|
||||
}
|
||||
//rule {
|
||||
// source_labels = ["hostname_fallback"]
|
||||
// target_label = "hostname"
|
||||
// action = "replace"
|
||||
// replacement = "${__label:hostname_fallback}" // Only if hostname is unset
|
||||
//}
|
||||
}
|
||||
|
||||
loki.write "loki" {
|
||||
|
||||
Reference in New Issue
Block a user