1
1
<%- |
2
2
String $header,
3
- Optional[ Array[Stdlib::Host]] $internal_proxy = undef ,
3
+ Array[Stdlib::Host] $internal_proxy = [] ,
4
4
Optional[Stdlib::Absolutepath] $internal_proxy_list = undef,
5
5
Optional[String] $proxies_header = undef,
6
6
Boolean $proxy_protocol = undef,
7
- Optional[ Array[Stdlib::Host]] $proxy_protocol_exceptions = undef ,
8
- Optional[ Array[Stdlib::IP::Address]] $trusted_proxy = undef ,
7
+ Array[Stdlib::Host] $proxy_protocol_exceptions = [] ,
8
+ Array[Stdlib::IP::Address] $trusted_proxy = [] ,
9
9
Optional[Stdlib::Absolutepath] $trusted_proxy_list = undef,
10
10
| -%>
11
11
# Declare the header field which should be parsed for useragent IP addresses
12
12
RemoteIPHeader <%= $header %>
13
13
14
- <%- if $internal_proxy { -%>
14
+ <%- unless $internal_proxy.empty { -%>
15
15
# Declare client intranet IP addresses trusted to present
16
16
# the RemoteIPHeader value
17
17
<%- $internal_proxy.each |$proxy| { -%>
@@ -32,13 +32,11 @@ RemoteIPProxiesHeader <%= $proxies_header %>
32
32
RemoteIPProxyProtocol On
33
33
<%- } -%>
34
34
35
- <%- if $proxy_protocol_exceptions { -%>
36
- <%- $proxy_protocol_exceptions.each |$exception| { -%>
35
+ <%- $proxy_protocol_exceptions.each |$exception| { -%>
37
36
RemoteIPProxyProtocolExceptions <%= $exception %>
38
- <%- } -%>
39
37
<%- } -%>
40
38
41
- <%- if $trusted_proxy { -%>
39
+ <%- unless $trusted_proxy.empty { -%>
42
40
# Declare client intranet IP addresses trusted to present
43
41
# the RemoteIPHeader value
44
42
<%- $trusted_proxy.each |$proxy| { -%>
0 commit comments