2025-01-01 02:02:00 -05:00
|
|
|
{ config, lib, ... }:
|
2024-10-22 21:08:23 -04:00
|
|
|
{
|
2025-01-17 19:55:34 -05:00
|
|
|
services.nginx.virtualHosts = lib.mkIf config.system.server.enable {
|
2025-02-25 03:03:43 -05:00
|
|
|
"www.nixfox.ca" = {
|
2025-01-17 19:55:34 -05:00
|
|
|
enableACME = true;
|
|
|
|
addSSL = true;
|
2025-01-20 15:40:01 -05:00
|
|
|
default = true;
|
2025-01-17 19:55:34 -05:00
|
|
|
root = "/var/www/landing-page";
|
|
|
|
};
|
2025-02-25 03:03:43 -05:00
|
|
|
"nixfox.ca" = {
|
2025-01-17 19:55:34 -05:00
|
|
|
enableACME = true;
|
|
|
|
addSSL = true;
|
2025-02-25 03:03:43 -05:00
|
|
|
globalRedirect = "www.nixfox.ca";
|
2025-03-04 17:24:48 -05:00
|
|
|
locations = {
|
|
|
|
"/.well-known/matrix/client".extraConfig = ''
|
|
|
|
default_type application/json;
|
|
|
|
return 200 '{
|
|
|
|
"m.homeserver": { "base_url": "https://matrix.nixfox.ca" },
|
|
|
|
"m.identity_server": { "base_url": "https://matrix.org" }
|
|
|
|
}';
|
|
|
|
'';
|
|
|
|
"/.well-known/matrix/server".extraConfig = ''
|
|
|
|
default_type application/json;
|
|
|
|
return 200 '{ "m.server": "matrix.nixfox.ca:443" }';
|
|
|
|
'';
|
|
|
|
};
|
2025-01-17 19:55:34 -05:00
|
|
|
};
|
2024-10-22 21:08:23 -04:00
|
|
|
};
|
|
|
|
}
|