feat(host/luna): strip .html
extension for blog
This commit is contained in:
parent
717dea38bb
commit
f497d0dfe2
@ -22,6 +22,12 @@
|
|||||||
forceSSL = true;
|
forceSSL = true;
|
||||||
enableACME = true;
|
enableACME = true;
|
||||||
root = inputs.blog.packages.${pkgs.system}.default;
|
root = inputs.blog.packages.${pkgs.system}.default;
|
||||||
|
locations."/".extraConfig = ''
|
||||||
|
if ($request_uri ~ ^/(.*)\.html(\?|$)) {
|
||||||
|
return 302 /$1;
|
||||||
|
}
|
||||||
|
try_files $uri $uri.html $uri/ =404;
|
||||||
|
'';
|
||||||
locations."/".index = "home.html";
|
locations."/".index = "home.html";
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user