chore: update oauth2_proxy service rename and kanidm update

This commit is contained in:
oddlama 2024-05-09 13:08:00 +02:00
parent 7b4d55ca80
commit 68d946653a
No known key found for this signature in database
GPG key ID: 14EFE510775FE39A
6 changed files with 45 additions and 34 deletions

View file

@ -3,7 +3,7 @@
nodes,
...
}: {
meta.oauth2_proxy = {
meta.oauth2-proxy = {
enable = true;
cookieDomain = config.repo.secrets.global.domains.me;
portalDomain = "oauth2.${config.repo.secrets.global.domains.me}";
@ -13,7 +13,7 @@
age.secrets.oauth2-cookie-secret = {
rekeyFile = ./secrets/oauth2-cookie-secret.age;
mode = "440";
group = "oauth2_proxy";
group = "oauth2-proxy";
};
# Mirror the original oauth2 secret, but prepend OAUTH2_PROXY_CLIENT_SECRET=
@ -32,10 +32,10 @@
${decrypt} ${lib.escapeShellArg (lib.head deps).file}
'';
mode = "440";
group = "oauth2_proxy";
group = "oauth2-proxy";
};
services.oauth2_proxy = let
services.oauth2-proxy = let
clientId = "web-sentinel";
in {
provider = "oidc";
@ -53,7 +53,7 @@
};
};
systemd.services.oauth2_proxy.serviceConfig.EnvironmentFile = [
systemd.services.oauth2-proxy.serviceConfig.EnvironmentFile = [
config.age.secrets.oauth2-cookie-secret.path
config.age.secrets.oauth2-client-secret.path
];

View file

@ -9,7 +9,7 @@
in {
wireguard.proxy-sentinel = {
client.via = "sentinel";
firewallRuleForNode.sentinel.allowedTCPPorts = [config.services.adguardhome.settings.bind_port];
firewallRuleForNode.sentinel.allowedTCPPorts = [config.services.adguardhome.settings.port];
};
nodes.sentinel = {
@ -17,7 +17,7 @@ in {
services.nginx = {
upstreams.adguardhome = {
servers."${config.wireguard.proxy-sentinel.ipv4}:${toString config.services.adguardhome.settings.bind_port}" = {};
servers."${config.wireguard.proxy-sentinel.ipv4}:${toString config.services.adguardhome.settings.port}" = {};
extraConfig = ''
zone adguardhome 64k;
keepalive 2;
@ -55,8 +55,8 @@ in {
# simpler sed dns.host_addr logic.
mutableSettings = false;
settings = {
bind_host = "0.0.0.0";
bind_port = 3000;
host = "0.0.0.0";
port = 3000;
dns = {
bind_hosts = [
# This dummy address passes the configuration check and will