From: Tom Hughes Date: Fri, 18 Oct 2019 09:50:37 +0000 (+0100) Subject: Use one worker per CPU with squid 3 and 4 X-Git-Url: https://git.openstreetmap.org/chef.git/commitdiff_plain/0364daf8925f1dbba90ee38d58ed2b096db5cffc Use one worker per CPU with squid 3 and 4 --- diff --git a/cookbooks/squid/templates/default/squid.conf.erb b/cookbooks/squid/templates/default/squid.conf.erb index 817fd5072..dabb406a3 100644 --- a/cookbooks/squid/templates/default/squid.conf.erb +++ b/cookbooks/squid/templates/default/squid.conf.erb @@ -5,6 +5,10 @@ visible_hostname <%= node.name %> #FIXME - configurable cache_mem <%= node[:squid][:cache_mem] %> +<% if node[:squid][:version] > 2 -%> + +workers <%= node[:cpu][:total] %> +<% end -%> max_filedescriptors 98304