heimdall: Split caddy config into separate file and add dendrite config

This commit is contained in:
Erwin Boskma 2024-04-24 13:58:04 +02:00
parent 1737374346
commit 7fa8cb1b01
Signed by: erwin
SSH key fingerprint: SHA256:/Wk1WZdLg+vQHs3in9qq7PsIp8SMzwGSk/RLZ5zPuZk
2 changed files with 40 additions and 22 deletions

View file

@ -0,0 +1,38 @@
{
services.caddy = {
virtualHosts = {
"datarift.nl" = {
extraConfig = ''
@webfinger-erwin {
path /.well-known/webfinger
query resource=acct:erwin@datarift.nl
}
respond @webfinger-erwin 200 {
body `{"subject":"acct:erwin@datarift.nl","links":[{"rel":"http://openid.net/specs/connect/1.0/issuer","href":"https://id.datarift.nl/realms/datarift"}]}`
close
}
'';
};
"git.datarift.nl" = {
extraConfig = ''
reverse_proxy gitea.barn-beaver.ts.net:3000
'';
};
"boskma.frl" = {
extraConfig = ''
header /.well-known/matrix/* Content-Type application/json
header /.well-known/matrix/* Access-Control-Allow-Origin *
respond /.well-known/matrix/server `{"m.server": "matrix.boskma.frl:443"}`
respond /.well-known/matrix/client `{"m.homeserver": {"base_url": "https://matrix.boskma.frl"}}`
'';
};
"matrix.boskma.frl" = {
extraConfig = ''
reverse_proxy /_matrix/* neo.barn-beaver.ts.net:8008
'';
};
};
};
}

View file

@ -9,6 +9,8 @@
../../users/root
../../users/erwin
./caddy
];
eboskma = {
@ -122,28 +124,6 @@
enable = true;
permitCertUid = "caddy";
};
caddy = {
virtualHosts = {
"datarift.nl" = {
extraConfig = ''
@webfinger-erwin {
path /.well-known/webfinger
query resource=acct:erwin@datarift.nl
}
respond @webfinger-erwin 200 {
body `{"subject":"acct:erwin@datarift.nl","links":[{"rel":"http://openid.net/specs/connect/1.0/issuer","href":"https://id.datarift.nl/realms/datarift"}]}`
close
}
'';
};
"git.datarift.nl" = {
extraConfig = ''
reverse_proxy gitea.barn-beaver.ts.net:3000
'';
};
};
};
};
security = {