diff options
author | Martin Weinelt <mweinelt@users.noreply.github.com> | 2021-08-08 15:03:06 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-08-08 15:03:06 +0200 |
commit | 611bc7c23b1ec86f12f2d2cd8a79f965b51d0432 (patch) | |
tree | d8de9e9178f589732f89f47b35b0625b56fc0164 /nixos/modules/services/networking/ntp | |
parent | 35937ee122ccf88ec391fc643516f502b43a925f (diff) | |
parent | 6f4e6cd819173f8d2aaebdc73b7583d6f10973bb (diff) | |
download | nixpkgs-611bc7c23b1ec86f12f2d2cd8a79f965b51d0432.tar nixpkgs-611bc7c23b1ec86f12f2d2cd8a79f965b51d0432.tar.gz nixpkgs-611bc7c23b1ec86f12f2d2cd8a79f965b51d0432.tar.bz2 nixpkgs-611bc7c23b1ec86f12f2d2cd8a79f965b51d0432.tar.lz nixpkgs-611bc7c23b1ec86f12f2d2cd8a79f965b51d0432.tar.xz nixpkgs-611bc7c23b1ec86f12f2d2cd8a79f965b51d0432.tar.zst nixpkgs-611bc7c23b1ec86f12f2d2cd8a79f965b51d0432.zip |
Merge pull request #111692 from lopsided98/chrony-initstepslew-types
nixos/chrony: split the initstepslew attrset into options
Diffstat (limited to 'nixos/modules/services/networking/ntp')
-rw-r--r-- | nixos/modules/services/networking/ntp/chrony.nix | 29 |
1 files changed, 19 insertions, 10 deletions
diff --git a/nixos/modules/services/networking/ntp/chrony.nix b/nixos/modules/services/networking/ntp/chrony.nix index a4b17bbbff5..ed61c178c68 100644 --- a/nixos/modules/services/networking/ntp/chrony.nix +++ b/nixos/modules/services/networking/ntp/chrony.nix @@ -81,17 +81,26 @@ in ''; }; - initstepslew = mkOption { - type = types.attrsOf (types.either types.bool types.int); - default = { - enabled = true; - threshold = 1000; # by default, same threshold as 'ntpd -g' (1000s) + initstepslew = { + enabled = mkOption { + type = types.bool; + default = true; + description = '' + Allow chronyd to make a rapid measurement of the system clock error + at boot time, and to correct the system clock by stepping before + normal operation begins. + ''; + }; + + threshold = mkOption { + type = types.either types.float types.int; + default = 1000; # by default, same threshold as 'ntpd -g' (1000s) + description = '' + The threshold of system clock error (in seconds) above which the + clock will be stepped. If the correction required is less than the + threshold, a slew is used instead. + ''; }; - description = '' - Allow chronyd to make a rapid measurement of the system clock error at - boot time, and to correct the system clock by stepping before normal - operation begins. - ''; }; directory = mkOption { |