diff options
| author | seth <[email protected]> | 2023-08-05 03:27:45 -0400 |
|---|---|---|
| committer | seth <[email protected]> | 2023-08-05 03:29:57 -0400 |
| commit | 328cc0182336b8b394702b02c4e0f6255a7174a2 (patch) | |
| tree | 7b1b5b9a7ae95bafd7a1606420d13f634be5ed09 /modules/nixos | |
| parent | 1b8d2d2ba704aedcdc6cad0faca7c8b689d314a8 (diff) | |
hosts!: prometheus -> victoria metrics
Diffstat (limited to 'modules/nixos')
| -rw-r--r-- | modules/nixos/server/services/promtail.nix | 17 |
1 files changed, 4 insertions, 13 deletions
diff --git a/modules/nixos/server/services/promtail.nix b/modules/nixos/server/services/promtail.nix index 73a8de2..95592f0 100644 --- a/modules/nixos/server/services/promtail.nix +++ b/modules/nixos/server/services/promtail.nix @@ -9,12 +9,6 @@ in { options.getchoo.server.services.promtail = { enable = mkEnableOption "enable promtail"; - port = mkOption { - type = types.port; - default = 3031; - description = "port for promtail"; - }; - clients = mkOption { type = types.listOf types.attrs; default = [{}]; @@ -25,17 +19,13 @@ in { config.services.promtail = mkIf cfg.enable { enable = true; configuration = { - server = { - http_listen_port = cfg.port; - grpc_listen_port = 0; - }; - positions = { - filename = "/tmp/positions.yaml"; - }; inherit (cfg) clients; + server.disable = true; + scrape_configs = [ { job_name = "journal"; + journal = { max_age = "12h"; labels = { @@ -43,6 +33,7 @@ in { host = "${config.networking.hostName}"; }; }; + relabel_configs = [ { source_labels = ["__journal__systemd_unit"]; |
