sonarr: port to vhost
This commit is contained in:
parent
65ba588d8e
commit
b378975769
@ -2,35 +2,21 @@
|
|||||||
|
|
||||||
let
|
let
|
||||||
domain = "htson.giugl.io";
|
domain = "htson.giugl.io";
|
||||||
auth_block = (import ./openid.nix { inherit lib; }).openresty_oidc_block;
|
|
||||||
|
|
||||||
utilities = import ./utilities.nix { inherit lib config; };
|
|
||||||
inherit (utilities) architectInterfaceAddress;
|
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
services = {
|
services.sonarr = {
|
||||||
sonarr = {
|
enable = true;
|
||||||
enable = true;
|
group = "media";
|
||||||
group = "media";
|
};
|
||||||
};
|
|
||||||
|
architect.vhost.${domain} = {
|
||||||
|
dnsInterfaces = [ "tailscale" "wireguard" ];
|
||||||
|
|
||||||
nginx.virtualHosts.${domain} = {
|
locations."/" = {
|
||||||
forceSSL = true;
|
port = 6969;
|
||||||
enableACME = true;
|
allowLan = true;
|
||||||
locations."/" = {
|
|
||||||
proxyPass = "http://127.0.0.1:8989";
|
|
||||||
extraConfig = auth_block {
|
|
||||||
access_role = "sonarr";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
networking.extraHosts = ''
|
|
||||||
${architectInterfaceAddress "lan"} ${domain}
|
|
||||||
${architectInterfaceAddress "wireguard"} ${domain}
|
|
||||||
${architectInterfaceAddress "tailscale"} ${domain}
|
|
||||||
'';
|
|
||||||
|
|
||||||
users.groups.media.members = [ "sonarr" ];
|
users.groups.media.members = [ "sonarr" ];
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user