deluge: Add OpenID auth
This commit is contained in:
parent
35dbc4f40e
commit
1be49e4835
@ -3,6 +3,7 @@
|
|||||||
let
|
let
|
||||||
domain = "htdel.giugl.io";
|
domain = "htdel.giugl.io";
|
||||||
network = import ./network.nix;
|
network = import ./network.nix;
|
||||||
|
auth_block = (import ./openid.nix).openresty_oidc_block;
|
||||||
in {
|
in {
|
||||||
services = {
|
services = {
|
||||||
deluge = {
|
deluge = {
|
||||||
@ -34,11 +35,12 @@ in {
|
|||||||
nginx.virtualHosts.${domain} = {
|
nginx.virtualHosts.${domain} = {
|
||||||
locations."/" = {
|
locations."/" = {
|
||||||
proxyPass = "http://localhost:8112";
|
proxyPass = "http://localhost:8112";
|
||||||
extraConfig = ''
|
extraConfig = auth_block {
|
||||||
allow 10.0.0.0/24;
|
realm = "master";
|
||||||
${lib.concatMapStrings (x: "allow ${x};") network.gdevices-wg}
|
client_id = "deluge";
|
||||||
deny all;
|
client_secret = "AGa1U9S1zkaM3TJVxtyx4Er76DBk1APR";
|
||||||
'';
|
redirect_uri = "https://${domain}";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user