diff --git a/machines/newton/syncthing.nix b/machines/newton/syncthing.nix index 14c17f4..32c68ae 100644 --- a/machines/newton/syncthing.nix +++ b/machines/newton/syncthing.nix @@ -3,6 +3,15 @@ sops.secrets."syncthing/key" = { }; sops.secrets."syncthing/cert" = { }; + # make sure folders exist writable + systemd.tmpfiles.rules = [ + "d /srv/data/ 0755 syncthing syncthing" + "d /srv/data/computer 0755 syncthing syncthing" + "d /srv/data/phone 0755 syncthing syncthing" + "d /srv/data/music 0755 syncthing syncthing" + "d /srv/data/photos 0755 syncthing syncthing" + ]; + services.syncthing = { enable = true; openDefaultPorts = true; diff --git a/machines/serverle/syncthing.nix b/machines/serverle/syncthing.nix index 1759eb9..be38a04 100644 --- a/machines/serverle/syncthing.nix +++ b/machines/serverle/syncthing.nix @@ -3,6 +3,16 @@ sops.secrets."syncthing/key" = { }; sops.secrets."syncthing/cert" = { }; + # make sure folders exist writable + systemd.tmpfiles.rules = [ + "d /srv/data/ 0755 syncthing syncthing" + "d /srv/data/computer 0755 syncthing syncthing" + "d /srv/data/phone 0755 syncthing syncthing" + "d /srv/data/music 0755 syncthing syncthing" + "d /srv/data/photos 0755 syncthing syncthing" + "d /srv/data/tmp/aria2 0755 syncthing syncthing" + ]; + services.syncthing = { enable = true; openDefaultPorts = true;