diff --git a/common/fragments/grafana.nix b/common/fragments/grafana.nix index 75bb3e1..d900a53 100644 --- a/common/fragments/grafana.nix +++ b/common/fragments/grafana.nix @@ -49,6 +49,16 @@ ]; }]; } + { + job_name = "process"; + static_configs = [{ + targets = [ + "localhost:${ + toString config.services.prometheus.exporters.process.port + }" + ]; + }]; + } ]; }; } diff --git a/common/fragments/prometheus_exporters.nix b/common/fragments/prometheus_exporters.nix index 68ea421..79e7314 100644 --- a/common/fragments/prometheus_exporters.nix +++ b/common/fragments/prometheus_exporters.nix @@ -20,6 +20,17 @@ enable = true; port = 9003; }; + process = { + enable = true; + port = 9005; + settings.process_names = [ + # Remove nix store path from process name + { + name = "{{.Matches.Wrapped}} {{ .Matches.Args }}"; + cmdline = [ "^/nix/store[^ ]*/(?P[^ /]*) (?P.*)" ]; + } + ]; + }; }; }; diff --git a/hosts/bloodletting/configuration.nix b/hosts/bloodletting/configuration.nix index 66e9f34..c504323 100644 --- a/hosts/bloodletting/configuration.nix +++ b/hosts/bloodletting/configuration.nix @@ -193,6 +193,8 @@ proxyPass = "http://unix:/run/mastodon-streaming/streaming.socket"; proxyWebsockets = true; }; + + extraConfig = "client_max_body_size 64M;"; }; };