Syncthing: Difference between revisions

From NixOS Wiki
imported>Srid
m Fix syntax
imported>Srid
home-manager
Line 16: Line 16:
};
};
</nowiki>
</nowiki>
== home-manager service ==
https://github.com/nix-community/home-manager/blob/master/modules/services/syncthing.nix

Revision as of 15:05, 13 September 2020

Available as a standalone package:

nix-env -iA nixos.syncthing

It can also be enabled as a service. You'll typically want to set the user and the config dir, as with the default values ("syncthing" for the user, "/var/lib/syncthing" for the dir) you won't be able to access the files:

services = {
    syncthing = {
        enable = true;
        user = "myusername";
        dataDir = "/home/myusername/Documents";
        configDir = "/home/myusername/Documents/.config/syncthing";
    };
};


home-manager service

https://github.com/nix-community/home-manager/blob/master/modules/services/syncthing.nix