]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/squid/templates/default/squid.conf.erb
Enable HTCP on tile caches
[chef.git] / cookbooks / squid / templates / default / squid.conf.erb
index fbb07641f1c05142a082f56bf53e131d28c19991..e6fd9bdd621c71f693f383e75b3a6033cd89cd99 100644 (file)
@@ -5,11 +5,19 @@ visible_hostname <%= node.name %>
 
 #FIXME - configurable
 cache_mem  <%= node[:squid][:cache_mem] %>
+<% if node[:squid][:version] > 2 -%>
+
+workers <%= node[:cpu][:total] %>
+
+error_log_languages off
+<% end -%>
 
 max_filedescriptors 98304
 
 #used by squidclient / munin
 http_port 3128
+#HTCP
+htcp_port 4827
 #ICP
 icp_port 3130
 log_icp_queries off
@@ -51,6 +59,9 @@ persistent_request_timeout 1 minutes
 <% else -%>
 client_idle_pconn_timeout 1 minutes
 <% end -%>
+<% if node[:squid][:version] > 3 -%>
+pconn_lifetime 5 minutes
+<% end -%>
 
 negative_ttl 15 seconds
 half_closed_clients off
@@ -143,6 +154,7 @@ logfile_rotate 0
 #MUST BE LAST ACL
 #--------------
 http_access deny all
+htcp_access deny all
 icp_access deny all
 #--------------