diff --git a/nixos/modules/services/networking/syncthing.nix b/nixos/modules/services/networking/syncthing.nix index e011172ffa7..d78a54a3327 100644 --- a/nixos/modules/services/networking/syncthing.nix +++ b/nixos/modules/services/networking/syncthing.nix @@ -426,7 +426,9 @@ in { ''; }; }; - syncthing-init = { + syncthing-init = mkIf ( + cfg.declarative.devices != {} || cfg.declarative.folders != {} + ) { after = [ "syncthing.service" ]; wantedBy = [ "multi-user.target" ];