diff --git a/applications/ldap.nix b/applications/ldap.nix index be574e4..5671859 100644 --- a/applications/ldap.nix +++ b/applications/ldap.nix @@ -91,7 +91,16 @@ Gonna use a priper nixos module for this "${cfg.domain.sub}.${cfg.domain.base}.${cfg.domain.tld}" = { forceSSL = true; useACMEHost = "skynet"; - root = "${inputs.skynet_ldap_frontend.defaultPackage."x86_64-linux"}"; + locations."/" = { + root = "${inputs.skynet_ldap_frontend.defaultPackage."x86_64-linux"}"; + # https://stackoverflow.com/a/38238001 + extraConfig = '' + if ($request_uri ~ ^/(.*)\.html) { + return 302 /$1; + } + try_files $uri $uri.html $uri/ =404; + ''; + }; }; };