bazarr: use vhost
This commit is contained in:
parent
da1b08c44a
commit
17d2e10345
@ -2,35 +2,25 @@
|
|||||||
|
|
||||||
let
|
let
|
||||||
domain = "htbaz.giugl.io";
|
domain = "htbaz.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.bazarr = {
|
||||||
bazarr = {
|
enable = true;
|
||||||
enable = true;
|
group = "media";
|
||||||
group = "media";
|
};
|
||||||
};
|
|
||||||
|
|
||||||
nginx.virtualHosts.${domain} = {
|
architect.vhost.${domain} = with config.architect.networks; {
|
||||||
forceSSL = true;
|
dnsInterfaces = [ "lan" "wireguard" "tailscale" ];
|
||||||
enableACME = true;
|
locations."/" = {
|
||||||
locations."/" = {
|
port = 6767;
|
||||||
proxyPass = "http://127.0.0.1:6767";
|
deny = [ lan.devices.router.address ];
|
||||||
extraConfig = auth_block {
|
allow = [
|
||||||
access_role = "bazarr";
|
lan.net
|
||||||
};
|
wireguard.net
|
||||||
};
|
tailscale.net
|
||||||
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
networking.extraHosts = ''
|
|
||||||
${architectInterfaceAddress "lan"} ${domain}
|
|
||||||
${architectInterfaceAddress "wireguard"} ${domain}
|
|
||||||
${architectInterfaceAddress "tailscale"} ${domain}
|
|
||||||
'';
|
|
||||||
|
|
||||||
users.groups.media.members = [ "bazarr" ];
|
users.groups.media.members = [ "bazarr" ];
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user