1 # DO NOT EDIT - This file is being maintained by Chef
4 cache_mem <%= node[:squid][:cache_mem] %>
6 max_filedescriptors 65536
8 #used by squidclient / munin
14 http_port 80 accel defaultsite=tile.openstreetmap.org tcpkeepalive=60,10,6 http11
16 cache_effective_user proxy
17 cache_effective_group proxy
20 cache_dir <%= node[:squid][:cache_dir] %>
21 cache_swap_log /var/spool/squid/%s
28 maximum_object_size 1048576 bytes
29 maximum_object_size_in_memory 64 KB
31 cache_replacement_policy heap LFUDA
32 memory_replacement_policy heap GDSF
34 server_persistent_connections on
35 persistent_request_timeout 1 minutes
37 negative_ttl 15 seconds
38 half_closed_clients off
41 read_timeout 90 seconds
42 request_timeout 90 seconds
43 connect_timeout 20 seconds
44 client_lifetime 1 hours
46 collapsed_forwarding on
47 refresh_stale_hit 300 seconds
49 #Recommended minimum configuration:
50 #----------------------------------
52 acl manager proto cache_object
53 acl localhost src 127.0.0.1/32
54 acl to_localhost dst 127.0.0.0/8
55 acl SSL_ports port 443
56 acl Safe_ports port 80 # http
57 acl Safe_ports port 21 # ftp
58 acl Safe_ports port 443 # https
59 acl Safe_ports port 70 # gopher
60 acl Safe_ports port 210 # wais
61 acl Safe_ports port 1025-65535 # unregistered ports
62 acl Safe_ports port 280 # http-mgmt
63 acl Safe_ports port 488 # gss-http
64 acl Safe_ports port 591 # filemaker
65 acl Safe_ports port 777 # multiling http
66 acl CONNECT method CONNECT
67 http_access allow manager localhost
69 http_access allow manager
71 http_access deny manager
72 http_access deny !Safe_ports
73 http_access deny CONNECT !SSL_ports
74 #----------------------------------
76 acl purge_hosts src 127.0.0.0/8
77 acl PURGE method purge
78 http_access allow purge purge_hosts
79 http_access deny purge
83 access_log <%= node[:squid][:access_log] %>
84 cache_log /var/log/squid/cache.log
92 refresh_pattern . 0 20% 4320
94 #ZERO required for logrotate to work properly
97 <% Dir.glob("/etc/squid/squid.conf.d/*.conf") do |file| -%>
98 <%= File.read(file) %>