2023-04-14 22:04:18 +00:00
|
|
|
{ pkgs, lib, ... }:
|
2023-04-13 22:12:24 +00:00
|
|
|
|
2023-04-13 20:53:38 +00:00
|
|
|
{
|
|
|
|
services.prowlarr = {
|
|
|
|
enable = true;
|
|
|
|
openFirewall = false;
|
|
|
|
};
|
|
|
|
|
|
|
|
systemd.services.prowlarr = {
|
2023-04-14 22:52:07 +00:00
|
|
|
bindsTo = [ "wg.service" ];
|
2023-04-14 22:04:18 +00:00
|
|
|
after = lib.mkForce [ "wg.service" ];
|
2023-04-13 20:53:38 +00:00
|
|
|
|
|
|
|
serviceConfig = {
|
|
|
|
NetworkNamespacePath = "/var/run/netns/wg";
|
2023-04-19 06:00:24 +00:00
|
|
|
BindReadOnlyPaths = [
|
|
|
|
"/etc/netns/wg/resolv.conf:/etc/resolv.conf:norbind"
|
|
|
|
"/etc/netns/wg/nsswitch.conf:/etc/nsswitch.conf:norbind"
|
|
|
|
];
|
2023-04-13 20:53:38 +00:00
|
|
|
};
|
|
|
|
};
|
2023-04-13 22:12:24 +00:00
|
|
|
|
2023-04-14 15:45:02 +00:00
|
|
|
services.nginx.virtualHosts."prowlarr.internal.kempkens.network" = {
|
|
|
|
quic = true;
|
|
|
|
http3 = true;
|
|
|
|
|
|
|
|
onlySSL = true;
|
|
|
|
useACMEHost = "internal.kempkens.network";
|
|
|
|
|
2023-04-14 23:29:59 +00:00
|
|
|
extraConfig = ''
|
|
|
|
client_max_body_size 32m;
|
|
|
|
'';
|
|
|
|
|
2023-04-14 15:45:02 +00:00
|
|
|
locations."/" = {
|
|
|
|
recommendedProxySettings = true;
|
2023-04-18 18:11:34 +00:00
|
|
|
proxyPass = "http://192.168.42.2:9696";
|
2023-04-14 23:27:47 +00:00
|
|
|
proxyWebsockets = true;
|
2023-04-14 15:45:02 +00:00
|
|
|
};
|
|
|
|
};
|
2023-04-13 20:53:38 +00:00
|
|
|
}
|