about summary refs log tree commit diff
path: root/nixos/modules/services/monitoring/prometheus/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixos/modules/services/monitoring/prometheus/default.nix')
-rw-r--r--nixos/modules/services/monitoring/prometheus/default.nix4
1 files changed, 3 insertions, 1 deletions
diff --git a/nixos/modules/services/monitoring/prometheus/default.nix b/nixos/modules/services/monitoring/prometheus/default.nix
index e6817ee227ab..82b97bd92f87 100644
--- a/nixos/modules/services/monitoring/prometheus/default.nix
+++ b/nixos/modules/services/monitoring/prometheus/default.nix
@@ -300,13 +300,14 @@ let
       };
       regex = mkOption {
         type = types.str;
+        default = "(.*)";
         description = ''
           Regular expression against which the extracted value is matched.
         '';
       };
       replacement = mkOption {
         type = types.str;
-        default = "";
+        default = "$1";
         description = ''
           Replacement value against which a regex replace is performed if the
           regular expression matches.
@@ -314,6 +315,7 @@ let
       };
       action = mkOption {
         type = types.enum ["replace" "keep" "drop"];
+        default = "replace";
         description = ''
           Action to perform based on regex matching.
         '';