18 lines
647 B
Nix
18 lines
647 B
Nix
|
{ inputs, ... }: {
|
||
|
services.caddy = {
|
||
|
enable = true;
|
||
|
|
||
|
virtualHosts."nothing.run, www.nothing.run".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.nothing.run:443"}`
|
||
|
respond /.well-known/matrix/client `{"m.homeserver":{"base_url":"https://matrix.nothing.run"},"org.matrix.msc3575.proxy":{"url":"https://matrix.nothing.run"}}`
|
||
|
|
||
|
root * ${inputs.website.website}
|
||
|
file_server
|
||
|
'';
|
||
|
|
||
|
};
|
||
|
networking.firewall.allowedTCPPorts = [ 80 443 ];
|
||
|
}
|