diff --git a/machines/newton/services.nix b/machines/newton/services.nix index a33c844..a925b22 100644 --- a/machines/newton/services.nix +++ b/machines/newton/services.nix @@ -72,6 +72,7 @@ in enable = true; passwordFile = secrets."paperless/password".path; extraConfig.PAPERLESS_ADMIN_USER = "felix"; + mediaDir = "/srv/data/docs"; }; # RSS aggregator and reader freshrss = { diff --git a/modules/services/paperless/default.nix b/modules/services/paperless/default.nix index e99b19e..4b4d4cc 100644 --- a/modules/services/paperless/default.nix +++ b/modules/services/paperless/default.nix @@ -21,6 +21,12 @@ in description = "Internal port for webui"; }; + mediaDir = mkOption { + type = types.path; + description = "Password for the defaultUser for FreshRSS."; + example = "/run/secrets/freshrss"; + }; + extraConfig = mkOption { type = types.attrs; default = { }; @@ -31,8 +37,7 @@ in config = lib.mkIf cfg.enable { services.paperless = { enable = true; - inherit (cfg) port; - mediaDir = "/srv/data/docs"; + inherit (cfg) port mediaDir; extraConfig = { PAPERLESS_OCR_LANGUAGE = "deu+eng"; } // cfg.extraConfig;