From 08675bba98bb0dbc61ffacb3e90a627aa201881f Mon Sep 17 00:00:00 2001 From: Kartik Gokte Date: Wed, 17 Jul 2024 16:06:37 +0530 Subject: [PATCH 1/2] prometheus-pve-exporter: 3.2.4 -> 3.4.3 From version 3.2.5, the package's name was changed upstream to use underscores (_) instead of dashes (-). Even though `pname` was changed to reflect this, the nix package itself will still be referenced by `prometheus-pve-exporter`, thus maintaining compatibility. --- pkgs/servers/monitoring/prometheus/pve-exporter.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/servers/monitoring/prometheus/pve-exporter.nix b/pkgs/servers/monitoring/prometheus/pve-exporter.nix index aaf5f46b075e..7bc1d9280a64 100644 --- a/pkgs/servers/monitoring/prometheus/pve-exporter.nix +++ b/pkgs/servers/monitoring/prometheus/pve-exporter.nix @@ -5,12 +5,12 @@ }: python3.pkgs.buildPythonApplication rec { - pname = "prometheus-pve-exporter"; - version = "3.2.4"; + pname = "prometheus_pve_exporter"; + version = "3.4.3"; src = fetchPypi { inherit pname version; - hash = "sha256-C7agnOUdtd4YncAiaPQaZqBJ8DKZoM1Fa+dr1F4xYgI="; + hash = "sha256-5xvTUOwBj3N0hxLKfAlEq8y8snoDb92f7o7u7j0RdhY="; }; propagatedBuildInputs = with python3.pkgs; [ From dbba11e241d1c8dfc51b58cb7a501e74f9600748 Mon Sep 17 00:00:00 2001 From: Kartik Gokte Date: Wed, 17 Jul 2024 16:09:11 +0530 Subject: [PATCH 2/2] nixos/prometheus-pve-exporter: added new options introduced in v3.4.3 --- .../services/monitoring/prometheus/exporters/pve.nix | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/nixos/modules/services/monitoring/prometheus/exporters/pve.nix b/nixos/modules/services/monitoring/prometheus/exporters/pve.nix index 8928577b6953..fa5852a4999d 100644 --- a/nixos/modules/services/monitoring/prometheus/exporters/pve.nix +++ b/nixos/modules/services/monitoring/prometheus/exporters/pve.nix @@ -114,6 +114,13 @@ in Collect PVE onboot status ''; }; + replication = mkOption { + type = types.bool; + default = true; + description = '' + Collect PVE replication info + ''; + }; }; }; serviceOpts = { @@ -128,6 +135,7 @@ in --${optionalString (!cfg.collectors.cluster) "no-"}collector.cluster \ --${optionalString (!cfg.collectors.resources) "no-"}collector.resources \ --${optionalString (!cfg.collectors.config) "no-"}collector.config \ + --${optionalString (!cfg.collectors.replication) "no-"}collector.replication \ ${optionalString (cfg.server.keyFile != null) "--server.keyfile ${cfg.server.keyFile}"} \ ${optionalString (cfg.server.certFile != null) "--server.certfile ${cfg.server.certFile}"} \ --config.file %d/configFile \