feat: add paperless
This commit is contained in:
parent
d888628e7b
commit
e7e82ae2d6
2
rpi4.nix
2
rpi4.nix
|
@ -26,6 +26,7 @@ in with builtins; {
|
|||
./services/home-assistant.nix
|
||||
./services/owntracks.nix
|
||||
./services/miniflux.nix
|
||||
./services/paperless.nix
|
||||
];
|
||||
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
@ -71,6 +72,7 @@ in with builtins; {
|
|||
"mqtt.felschr.com"
|
||||
"owntracks.felschr.com"
|
||||
"etebase.felschr.com"
|
||||
"paperless.felschr.com"
|
||||
];
|
||||
};
|
||||
|
||||
|
|
22
services/paperless.nix
Normal file
22
services/paperless.nix
Normal file
|
@ -0,0 +1,22 @@
|
|||
{ config, pkgs, ... }:
|
||||
|
||||
let port = 28981;
|
||||
in {
|
||||
services.paperless-ng = {
|
||||
enable = true;
|
||||
inherit port;
|
||||
passwordFile = "/etc/nixos/secrets/paperless";
|
||||
extraConfig = { PAPERLESS_OCR_LANGUAGE = "deu+eng"; };
|
||||
};
|
||||
|
||||
services.nginx = {
|
||||
virtualHosts."paperless.felschr.com" = {
|
||||
enableACME = true;
|
||||
forceSSL = true;
|
||||
locations."/" = {
|
||||
proxyPass = "http://localhost:${toString port}";
|
||||
proxyWebsockets = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Reference in a new issue