nixos/chrony: don't emit initstepslew when servers is empty
Setting the server list to be empty is useful e.g. for hardware-only or virtualized reference clocks that are passed through to the system directly. In this case, initstepslew has no effect, so don't emit it. Signed-off-by: Austin Seipp <aseipp@pobox.com>
This commit is contained in:
parent
22926c8b84
commit
7b8d9700e1
@ -12,7 +12,7 @@ let
|
||||
${concatMapStringsSep "\n" (server: "server " + server) cfg.servers}
|
||||
|
||||
${optionalString
|
||||
cfg.initstepslew.enabled
|
||||
(cfg.initstepslew.enabled && (cfg.servers != []))
|
||||
"initstepslew ${toString cfg.initstepslew.threshold} ${concatStringsSep " " cfg.initstepslew.servers}"
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user