feat: adds liv.town to nginx

This commit is contained in:
Ahwx 2024-07-17 03:20:00 +02:00
parent a77137731d
commit 7af36d0e25

View file

@ -10,6 +10,11 @@ let
return 200 '${builtins.toJSON data}'; return 200 '${builtins.toJSON data}';
''; '';
in { in {
imports = [
../liv-town.nix # If using Matrix, also require website, TODO: should probably be the other way around.
];
security.acme = { security.acme = {
acceptTerms = true; acceptTerms = true;
defaults.email = "ahwx@ahwx.org"; defaults.email = "ahwx@ahwx.org";
@ -81,9 +86,7 @@ in {
# It's also possible to do a redirect here or something else, this vhost is not # It's also possible to do a redirect here or something else, this vhost is not
# needed for Matrix. It's recommended though to *not put* element # needed for Matrix. It's recommended though to *not put* element
# here, see also the section about Element. # here, see also the section about Element.
locations."/".extraConfig = '' locations."/".proxyPass = "http://[::1]:4321";
return 404;
'';
# Forward all Matrix API calls to the synapse Matrix homeserver. A trailing slash # Forward all Matrix API calls to the synapse Matrix homeserver. A trailing slash
# *must not* be used here. # *must not* be used here.
locations."/_matrix".proxyPass = "http://[::1]:8008"; locations."/_matrix".proxyPass = "http://[::1]:8008";