diff --git a/hosts/shan/calibre-web.nix b/hosts/shan/calibre-web.nix index 8109844..a5b2bee 100644 --- a/hosts/shan/calibre-web.nix +++ b/hosts/shan/calibre-web.nix @@ -4,9 +4,15 @@ enable = true; options = { enableBookUploading = true; + calibreLibrary = "/mnt/books"; }; }; + systemd.services.calibre-web = { + after = [ "mnt-books.mount" ]; + requires = [ "mnt-books.mount" ]; + }; + fileSystems."/mnt/books" = { device = "192.168.178.21:/mnt/Fort/data/books"; fsType = "nfs"; diff --git a/options/server/navidrome.nix b/options/server/navidrome.nix index 688c3cd..e8509ca 100644 --- a/options/server/navidrome.nix +++ b/options/server/navidrome.nix @@ -76,6 +76,9 @@ in }; systemd.services.navidrome = { + after = mkIf (cfg.library.type == "nfs") [ "mnt-music.mount" ]; + requires = mkIf (cfg.library.type == "nfs") [ "mnt-music.mount" ]; + serviceConfig = { Restart = cfg.restartPolicy; EnvironmentFile = config.age.secrets.navidrome.path;