2022-12-15 14:58:34 +00:00
|
|
|
{
|
|
|
|
pkgs,
|
|
|
|
lib,
|
|
|
|
...
|
|
|
|
}: {
|
2023-08-01 19:48:37 +01:00
|
|
|
options = {
|
|
|
|
services.nginx.virtualHosts = lib.mkOption {
|
|
|
|
type = lib.types.attrsOf (lib.types.submodule {
|
|
|
|
config.http3 = lib.mkDefault true;
|
|
|
|
});
|
|
|
|
};
|
2022-12-15 14:58:34 +00:00
|
|
|
};
|
|
|
|
|
2023-08-01 19:48:37 +01:00
|
|
|
config = {
|
|
|
|
security.acme = {
|
|
|
|
defaults = {email = "chaoticryptidz@owo.monster";};
|
|
|
|
acceptTerms = true;
|
|
|
|
};
|
|
|
|
|
|
|
|
services.nginx = {
|
|
|
|
enable = true;
|
|
|
|
package = pkgs.nginxQuic;
|
|
|
|
recommendedGzipSettings = true;
|
|
|
|
recommendedOptimisation = true;
|
|
|
|
recommendedProxySettings = true;
|
|
|
|
recommendedTlsSettings = true;
|
|
|
|
commonHttpConfig = "";
|
|
|
|
clientMaxBodySize = lib.mkDefault "512m";
|
|
|
|
serverNamesHashBucketSize = 1024;
|
|
|
|
};
|
|
|
|
|
|
|
|
services.logrotate.settings.nginx = {
|
|
|
|
minsize = "50M";
|
|
|
|
rotate = "4"; # 4 files of 50mb each
|
|
|
|
compress = "";
|
|
|
|
};
|
|
|
|
|
|
|
|
services.logrotate.settings.nginx.enable = true;
|
2021-12-28 21:42:46 +00:00
|
|
|
};
|
2022-11-02 11:32:03 +00:00
|
|
|
}
|