test minimal nginx

This commit is contained in:
Dmitriy Kholkin 2021-10-25 23:20:08 +03:00
parent 27c520a878
commit 4ed7bc9c31
2 changed files with 41 additions and 0 deletions

View File

@ -0,0 +1,39 @@
{ pkgs, config, lib, ... }: {
services.nginx = {
enable = true;
recommendedTlsSettings = true;
recommendedOptimisation = true;
recommendedGzipSettings = true;
recommendedProxySettings = true;
appendHttpConfig = "charset utf-8;";
virtualHosts = let
default = {
forceSSL = false;
enableACME = false;
};
in {
"ataraxiadev.com" = {
default = true;
locations."/" = {
root = "/var/lib/ataraxiadev.com";
# index = "index.txt";
};
locations."/.well-known" = {
proxyPass = "http://localhost:13748";
};
locations."/_matrix" = {
proxyPass = "http://localhost:13748";
};
} // default;
"matrix.ataraxiadev.com" = {
locations."/" = {
proxyPass = "http://localhost:13748";
};
} // default;
};
};
# security.acme = {
# email = "ataraxiadev@ataraxiadev.com";
# acceptTerms = true;
# };
}

View File

@ -19,5 +19,7 @@
zsh zsh
direnv direnv
nginx
]; ];
} }