From 88d1da8e5d94202c88d65816bb5793829f1baa7d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Tue, 10 Nov 2020 10:28:06 +0100 Subject: [PATCH] nixos/promtail: use json type for configuration --- nixos/modules/services/logging/promtail.nix | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/nixos/modules/services/logging/promtail.nix b/nixos/modules/services/logging/promtail.nix index 834bb99bb1d6..1d3e9d8e9b99 100644 --- a/nixos/modules/services/logging/promtail.nix +++ b/nixos/modules/services/logging/promtail.nix @@ -11,20 +11,7 @@ in { enable = mkEnableOption "the Promtail ingresser"; configuration = mkOption { - type = with lib.types; let - valueType = nullOr (oneOf [ - bool - int - float - str - (lazyAttrsOf valueType) - (listOf valueType) - ]) // { - description = "JSON value"; - emptyValue.value = {}; - deprecationMessage = null; - }; - in valueType; + type = (pkgs.formats.json {}).type; description = '' Specify the configuration for Promtail in Nix. '';