nzbget: vhost
This commit is contained in:
parent
edf4ba07ee
commit
0698f9b8db
@ -2,35 +2,21 @@
|
|||||||
|
|
||||||
let
|
let
|
||||||
domain = "htnzb.giugl.io";
|
domain = "htnzb.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.nzbget = {
|
||||||
nzbget = {
|
enable = true;
|
||||||
enable = true;
|
group = "media";
|
||||||
group = "media";
|
};
|
||||||
};
|
|
||||||
|
|
||||||
nginx.virtualHosts.${domain} = {
|
architect.vhost.${domain} = {
|
||||||
forceSSL = true;
|
dnsInterfaces = [ "tailscale" "wireguard" "lan" ];
|
||||||
enableACME = true;
|
|
||||||
locations."/" = {
|
locations."/" = {
|
||||||
proxyPass = "http://127.0.0.1:6789";
|
port = 6789;
|
||||||
extraConfig = auth_block {
|
allowLan = true;
|
||||||
access_role = "nzbget";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
networking.extraHosts = ''
|
|
||||||
${architectInterfaceAddress "lan"} ${domain}
|
|
||||||
${architectInterfaceAddress "wireguard"} ${domain}
|
|
||||||
${architectInterfaceAddress "tailscale"} ${domain}
|
|
||||||
'';
|
|
||||||
|
|
||||||
users.groups.media.members = [ "nzbget" ];
|
users.groups.media.members = [ "nzbget" ];
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user