many new stuff for zitadel
This commit is contained in:
parent
d4ebe58264
commit
e122f8d410
8 changed files with 600 additions and 30 deletions
34
hosts/h001/mods/oauth2-proxy.nix
Normal file
34
hosts/h001/mods/oauth2-proxy.nix
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
{ config, ... }:
|
||||
{
|
||||
services.oauth2-proxy = {
|
||||
enable = true;
|
||||
httpAddress = "http://127.0.0.1:4180";
|
||||
# package = pkgsUnstable.oauth2-proxy;
|
||||
provider = "oidc";
|
||||
reverseProxy = true;
|
||||
redirectURL = "https://sso-proxy.joshuabell.xyz/oauth2/callback";
|
||||
validateURL = "https://sso.joshuabell.xyz/oauth2/";
|
||||
oidcIssuerUrl = "https://sso.joshuabell.xyz:443";
|
||||
keyFile = config.age.secrets.oauth2_proxy_zitadel_client_secret.path;
|
||||
# nginx.domain = "sso-proxy.joshuabell.xyz";
|
||||
# email.domains = [ ];
|
||||
# extraConfig = {
|
||||
# whitelist-domain = ".joshuabell.xyz";
|
||||
# cookie-domain = ".joshuabell.xyz";
|
||||
# };
|
||||
};
|
||||
|
||||
services.nginx.virtualHosts."sso-proxy.joshuabell.xyz" = {
|
||||
locations = {
|
||||
"/" = {
|
||||
proxyWebsockets = true;
|
||||
recommendedProxySettings = true;
|
||||
proxyPass = "http://127.0.0.1:4180";
|
||||
extraConfig = ''
|
||||
proxy_set_header X-Forwarded-Proto https;
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue