diff options
author | KFears <kfearsoff@gmail.com> | 2022-08-28 15:56:46 +0400 |
---|---|---|
committer | KFears <kfearsoff@gmail.com> | 2022-08-28 17:27:51 +0400 |
commit | 7f227409836dcdd49024dc76417544b407f99e7c (patch) | |
tree | bdb67117e7751c23709fa590f00acdb00e64a29c /nixos | |
parent | 0e1f66693f266b244e620fd451cb09634ef457d8 (diff) | |
download | nixlib-7f227409836dcdd49024dc76417544b407f99e7c.tar nixlib-7f227409836dcdd49024dc76417544b407f99e7c.tar.gz nixlib-7f227409836dcdd49024dc76417544b407f99e7c.tar.bz2 nixlib-7f227409836dcdd49024dc76417544b407f99e7c.tar.lz nixlib-7f227409836dcdd49024dc76417544b407f99e7c.tar.xz nixlib-7f227409836dcdd49024dc76417544b407f99e7c.tar.zst nixlib-7f227409836dcdd49024dc76417544b407f99e7c.zip |
nixos/syncthing: fix path setting for versioning
Syncthing config XML uses `fsPath` setting for specifying the path to the versioning folder. This commit adds `services.syncthing.folders.<name>.versioning.fsPath` option to enable this functionality declaratively. Previously, `versioning.params.versionsPath` was used, which doesn't work.
Diffstat (limited to 'nixos')
-rw-r--r-- | nixos/modules/services/networking/syncthing.nix | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/nixos/modules/services/networking/syncthing.nix b/nixos/modules/services/networking/syncthing.nix index 373fd03223d6..2b029be19cf0 100644 --- a/nixos/modules/services/networking/syncthing.nix +++ b/nixos/modules/services/networking/syncthing.nix @@ -268,10 +268,10 @@ in { { versioning = { type = "staggered"; + fsPath = "/syncthing/backup"; params = { cleanInterval = "3600"; maxAge = "31536000"; - versionsPath = "/syncthing/backup"; }; }; } @@ -296,6 +296,14 @@ in { See <https://docs.syncthing.net/users/versioning.html>. ''; }; + fsPath = mkOption { + default = ""; + type = either str path; + description = mdDoc '' + Path to the versioning folder. + See <https://docs.syncthing.net/users/versioning.html>. + ''; + }; params = mkOption { type = attrsOf (either str path); description = mdDoc '' |