servo: nginx stateless deployment of the main blog

i.e. no need to run `make publish` when rebuilding the blog anymore.
instead, push blog changes, then `nix flake update; nixos-rebuild switch`
This commit is contained in:
2022-10-11 05:27:51 -07:00
parent 590c81c5db
commit 711778a975

View File

@@ -6,13 +6,17 @@
# web blog/personal site # web blog/personal site
services.nginx.virtualHosts."uninsane.org" = { services.nginx.virtualHosts."uninsane.org" = {
root = "/var/lib/uninsane/root"; root = "${pkgs.uninsane-dot-org}/share/uninsane-dot-org";
# a lot of places hardcode https://uninsane.org, # a lot of places hardcode https://uninsane.org,
# and then when we mix http + non-https, we get CORS violations # and then when we mix http + non-https, we get CORS violations
# and things don't look right. so force SSL. # and things don't look right. so force SSL.
forceSSL = true; forceSSL = true;
enableACME = true; enableACME = true;
# uninsane.org/share/foo => /var/lib/uninsane/root/share/foo.
# yes, nginx does not strip the prefix when evaluating against the root.
locations."/share".root = "/var/lib/uninsane/root";
# allow matrix users to discover that @user:uninsane.org is reachable via matrix.uninsane.org # allow matrix users to discover that @user:uninsane.org is reachable via matrix.uninsane.org
locations."= /.well-known/matrix/server".extraConfig = locations."= /.well-known/matrix/server".extraConfig =
let let