diff options
Diffstat (limited to 'nixpkgs/nixos/modules/services/monitoring/prometheus/exporters/mongodb.nix')
-rw-r--r-- | nixpkgs/nixos/modules/services/monitoring/prometheus/exporters/mongodb.nix | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/nixpkgs/nixos/modules/services/monitoring/prometheus/exporters/mongodb.nix b/nixpkgs/nixos/modules/services/monitoring/prometheus/exporters/mongodb.nix index 1ed6bbf0325d..288434e93abb 100644 --- a/nixpkgs/nixos/modules/services/monitoring/prometheus/exporters/mongodb.nix +++ b/nixpkgs/nixos/modules/services/monitoring/prometheus/exporters/mongodb.nix @@ -1,9 +1,17 @@ { config, lib, pkgs, options, ... }: -with lib; - let cfg = config.services.prometheus.exporters.mongodb; + inherit (lib) + mkOption + types + optionalString + getExe + length + concatStringsSep + concatMapStringsSep + escapeShellArgs + ; in { port = 9216; @@ -12,13 +20,13 @@ in type = types.str; default = "mongodb://localhost:27017/test"; example = "mongodb://localhost:27017/test"; - description = lib.mdDoc "MongoDB URI to connect to."; + description = "MongoDB URI to connect to."; }; collStats = mkOption { type = types.listOf types.str; default = [ ]; example = [ "db1.coll1" "db2" ]; - description = lib.mdDoc '' + description = '' List of comma separared databases.collections to get $collStats ''; }; @@ -26,7 +34,7 @@ in type = types.listOf types.str; default = [ ]; example = [ "db1.coll1" "db2" ]; - description = lib.mdDoc '' + description = '' List of comma separared databases.collections to get $indexStats ''; }; @@ -34,12 +42,12 @@ in type = types.listOf types.str; default = [ ]; example = [ "diagnosticdata" "replicasetstatus" "dbstats" "topmetrics" "currentopmetrics" "indexstats" "dbstats" "profile" ]; - description = lib.mdDoc "Enabled collectors"; + description = "Enabled collectors"; }; collectAll = mkOption { type = types.bool; default = false; - description = lib.mdDoc '' + description = '' Enable all collectors. Same as specifying all --collector.<name> ''; }; @@ -47,7 +55,7 @@ in type = types.str; default = "/metrics"; example = "/metrics"; - description = lib.mdDoc "Metrics expose path"; + description = "Metrics expose path"; }; }; serviceOpts = { |