nix/pkgs/pomerium: allow unitless 0

This commit is contained in:
Luke Granger-Brown 2021-03-14 14:40:54 +00:00
parent 36577c5bba
commit 7273c31af5

View file

@ -6,7 +6,7 @@ let
goDuration = types.mkOptionType {
name = "goDuration";
description = "Go duration (https://golang.org/pkg/time/#ParseDuration)";
check = x: types.str.check x && builtins.match "(-?[0-9]+(\.[0-9]+)?(ns|us|µs|ms|s|m|h))+" x != null;
check = x: types.str.check x && builtins.match "((-?[0-9]+(\.[0-9]+)?(ns|us|µs|ms|s|m|h))+|0)" x != null;
inherit (types.str) merge;
};
in