diff --git a/bundles/nginx/files/nginx.conf b/bundles/nginx/files/nginx.conf index d3c1361..f4beed0 100644 --- a/bundles/nginx/files/nginx.conf +++ b/bundles/nginx/files/nginx.conf @@ -1,6 +1,6 @@ pid /var/run/nginx.pid; user www-data; -worker_processes 10; +worker_processes ${worker_processes}; % for module in sorted(modules): load_module modules/ngx_${module}_module.so; @@ -22,6 +22,8 @@ http { tcp_nopush on; client_max_body_size 32G; ssl_dhparam "/etc/ssl/certs/dhparam.pem"; + # dont show nginx version + server_tokens off; % if node.has_bundle('php'): upstream php-handler { diff --git a/bundles/nginx/items.py b/bundles/nginx/items.py index 0fddc0c..b8f5849 100644 --- a/bundles/nginx/items.py +++ b/bundles/nginx/items.py @@ -32,6 +32,7 @@ files = { 'content_type': 'mako', 'context': { 'modules': node.metadata.get('nginx/modules'), + 'worker_processes': node.metadata.get('vm/cores'), }, 'triggers': { 'svc_systemd:nginx:restart',