diff --git a/hosts/appview/services/nginx.nix b/hosts/appview/services/nginx.nix index 10d3310..721f7a2 100644 --- a/hosts/appview/services/nginx.nix +++ b/hosts/appview/services/nginx.nix @@ -13,8 +13,12 @@ in { services.nginx = { enable = true; + prependConfig = '' + worker_processes auto; + worker_rlimit_nofile 65536; + ''; eventsConfig = '' - worker_connections 1024; + worker_connections 16384; ''; # bot blocking appendHttpConfig = '' @@ -182,6 +186,8 @@ in { }; }; + systemd.services.nginx.serviceConfig.LimitNOFILE = 65536; + # Open firewall ports networking.firewall.allowedTCPPorts = [80 443 2222 22 3333];