From fd670627e66259706823f53f905e0f9cd8e53905 Mon Sep 17 00:00:00 2001 From: Ingolf Wagner Date: Wed, 8 Feb 2023 13:08:21 +0100 Subject: [PATCH] improve loki logging --- nixos/machines/pepe/loki-promtail.nix | 14 ++++++++++---- nixos/machines/robi/loki-promtail.nix | 14 ++++++++++---- 2 files changed, 20 insertions(+), 8 deletions(-) diff --git a/nixos/machines/pepe/loki-promtail.nix b/nixos/machines/pepe/loki-promtail.nix index 56bb507..1c64287 100644 --- a/nixos/machines/pepe/loki-promtail.nix +++ b/nixos/machines/pepe/loki-promtail.nix @@ -22,10 +22,16 @@ host = config.networking.hostName; }; }; - relabel_configs = [{ - source_labels = [ "__journal__systemd_unit" ]; - target_label = "unit"; - }]; + relabel_configs = [ + { + source_labels = [ "__journal__systemd_unit" ]; + target_label = "unit"; + } + { + source_labels = [ "__journal__transport" ]; + target_label = "transport"; + } + ]; } ]; diff --git a/nixos/machines/robi/loki-promtail.nix b/nixos/machines/robi/loki-promtail.nix index 56bb507..1c64287 100644 --- a/nixos/machines/robi/loki-promtail.nix +++ b/nixos/machines/robi/loki-promtail.nix @@ -22,10 +22,16 @@ host = config.networking.hostName; }; }; - relabel_configs = [{ - source_labels = [ "__journal__systemd_unit" ]; - target_label = "unit"; - }]; + relabel_configs = [ + { + source_labels = [ "__journal__systemd_unit" ]; + target_label = "unit"; + } + { + source_labels = [ "__journal__transport" ]; + target_label = "transport"; + } + ]; } ];