File tree 2 files changed +51
-6
lines changed
2 files changed +51
-6
lines changed Original file line number Diff line number Diff line change
1
+ # = Class: squid
2
+ #
3
+ # Base Squid class
4
+ #
5
+ # == Parameters
6
+ #
7
+ # [*cache_dir*]
8
+ # String. Filesystem location to locate cache
9
+ # Default: /var/spool/squid3
10
+ #
11
+ # [*cache_dir_size*]
12
+ # Integer. Size in MB of cache to keep
13
+ # Default: 5000
14
+ #
15
+ # [*port*]
16
+ # Integer. Port for squid to listen on
17
+ # Default: 3128
18
+ #
19
+ # [*maximum_object_size*]
20
+ # Integer. Biggest object to cache in MB
21
+ # Default: 3128
22
+ #
23
+ # [*http_access*]
24
+ # Array of strings. HTTP access list rules.
25
+ # Default: []
26
+ # Example: [ 'allow localnet', 'deny mynet' ]
27
+ #
28
+ # [*cache_peer*]
29
+ # Array of strings. Upstream caches to peer with
30
+ # Default: []
31
+ # Example: [ 'squid3.example.com' ]
32
+ #
33
+ # [*cache_peer_access*]
34
+ # Array of strings. ACL entries for cache peers
35
+ # Default: []
36
+ #
37
+ # [*never_direct*]
38
+ # Array of strings. Hosts to connect directly to
39
+ # Default: []
40
+ # Example: [ 'directconnect1.example.com' ]
41
+ #
42
+ # [*cache_only*]
43
+ # Boolean. Use the cache never
44
+ # Default: false
45
+ #
1
46
# Puppet module to manage the squid http proxy server
2
47
# Source: https://github.com/pro-puppet/puppet-module-squid
3
48
10
55
$cache_peer = undef ,
11
56
$cache_peer_access = undef ,
12
57
$never_direct = undef ,
13
- $cache_only = undef ,
58
+ $cache_only = false ,
14
59
) inherits squid::params {
15
60
16
61
Original file line number Diff line number Diff line change @@ -20,11 +20,11 @@ http_access deny !Safe_ports
20
20
http_access deny CONNECT !SSL_ports
21
21
http_access allow localnet
22
22
http_access allow localhost
23
- <% if @http_access -%>
24
- <% @http_access.each do |val| -%>
23
+ <% if @http_access -%>
24
+ <% @http_access.each do |val| -%>
25
25
http_access <%= val %>
26
- <% end -%>
27
- <% end -%>
26
+ <% end -%>
27
+ <% end -%>
28
28
http_access deny all
29
29
http_port <%= @port %>
30
30
maximum_object_size <%= @maximum_object_size %> MB
@@ -41,7 +41,7 @@ refresh_all_ims on
41
41
cache_peer <%= val %>
42
42
<% end -%>
43
43
<% end -%>
44
- <% if @cache_peer_access -%>
44
+ <% if @cache_peer_access -%>
45
45
<% @cache_peer_access.each do |val| -%>
46
46
cache_peer_access <%= val %>
47
47
<% end -%>
You can’t perform that action at this time.
0 commit comments