summary refs log tree commit diff
path: root/nixos/modules/services/monitoring/prometheus/default.nix
diff options
context:
space:
mode:
authoroida <oida@users.noreply.github.com>2016-10-07 11:04:52 +0200
committerRobin Gloster <mail@glob.in>2016-10-09 11:37:33 +0200
commit725e04cc018f78a963c55e11ca2525c1cef30de5 (patch)
treea78740e223418104fef07d3e551bc2f1bf8a4c0c /nixos/modules/services/monitoring/prometheus/default.nix
parent52d12b473af0dfbf7f5af1bd75ac5a5f2366f887 (diff)
downloadnixlib-725e04cc018f78a963c55e11ca2525c1cef30de5.tar
nixlib-725e04cc018f78a963c55e11ca2525c1cef30de5.tar.gz
nixlib-725e04cc018f78a963c55e11ca2525c1cef30de5.tar.bz2
nixlib-725e04cc018f78a963c55e11ca2525c1cef30de5.tar.lz
nixlib-725e04cc018f78a963c55e11ca2525c1cef30de5.tar.xz
nixlib-725e04cc018f78a963c55e11ca2525c1cef30de5.tar.zst
nixlib-725e04cc018f78a963c55e11ca2525c1cef30de5.zip
prometheus module: added default option values for relabel_config
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.
         '';