update paperless

This commit is contained in:
Ingolf Wagner 2024-05-12 09:32:04 +02:00
parent 60422a1900
commit 285b1a1963
No known key found for this signature in database
GPG key ID: 76BF5F1928B9618B
2 changed files with 14 additions and 4 deletions

View file

@ -12,6 +12,13 @@
}; };
}; };
services.permown."/var/lib/paperless/consume" = {
owner = "paperless";
group = "paperless";
directory-mode = "755";
file-mode = "640";
};
networking.firewall.interfaces.wg0.allowedTCPPorts = [ config.services.paperless.port ]; networking.firewall.interfaces.wg0.allowedTCPPorts = [ config.services.paperless.port ];
services.nginx.virtualHosts."paperless.${config.networking.hostName}.private" = { services.nginx.virtualHosts."paperless.${config.networking.hostName}.private" = {
@ -20,6 +27,9 @@
deny all; deny all;
''; '';
locations."/" = { locations."/" = {
extraConfig = ''
client_max_body_size 500M;
'';
proxyPass = "http://localhost:${toString config.services.paperless.port}"; proxyPass = "http://localhost:${toString config.services.paperless.port}";
proxyWebsockets = true; proxyWebsockets = true;
}; };

View file

@ -4,10 +4,10 @@
client_name="ipad tina" client_name="ipad tina"
client_ip=10.100.0.9 client_ip=10.100.0.9
private_key=$( wg genkey ) private_key=$(wg genkey)
public_key=$( echo "$private_key" | wg pubkey ) public_key=$(echo "$private_key" | wg pubkey)
cat <<EOF > client.conf cat <<EOF >client.conf
[Interface] [Interface]
Address = ${client_ip}/32 Address = ${client_ip}/32
MTU = 1280 MTU = 1280
@ -39,4 +39,4 @@ for quick configuration
EOF EOF
qrencode -t ansiutf8 < client.conf qrencode -t ansiutf8 <client.conf