Mercurial > repos > other > Puppet
comparison modules/apache/manifests/mod/remoteip.pp @ 437:b8d6ada284dd
Update Apache module to latest version
Also converted some params to ints to match
author | IBBoard <dev@ibboard.co.uk> |
---|---|
date | Sun, 14 Aug 2022 11:30:13 +0100 |
parents | d9352a684e62 |
children | adf6fe9bbc17 |
comparison
equal
deleted
inserted
replaced
436:6293839019d0 | 437:b8d6ada284dd |
---|---|
58 Optional[Array[Variant[Stdlib::Host,Stdlib::IP::Address]]] $internal_proxy = undef, | 58 Optional[Array[Variant[Stdlib::Host,Stdlib::IP::Address]]] $internal_proxy = undef, |
59 Optional[Array[Variant[Stdlib::Host,Stdlib::IP::Address]]] $proxy_ips = undef, | 59 Optional[Array[Variant[Stdlib::Host,Stdlib::IP::Address]]] $proxy_ips = undef, |
60 Optional[Stdlib::Absolutepath] $internal_proxy_list = undef, | 60 Optional[Stdlib::Absolutepath] $internal_proxy_list = undef, |
61 Optional[String] $proxies_header = undef, | 61 Optional[String] $proxies_header = undef, |
62 Boolean $proxy_protocol = false, | 62 Boolean $proxy_protocol = false, |
63 Optional[Array[Stdlib::Host]] $proxy_protocol_exceptions = undef, | 63 Optional[Array[Variant[Stdlib::Host,Stdlib::IP::Address]]] $proxy_protocol_exceptions = undef, |
64 Optional[Array[Stdlib::Host]] $trusted_proxy = undef, | 64 Optional[Array[Stdlib::Host]] $trusted_proxy = undef, |
65 Optional[Array[Stdlib::Host]] $trusted_proxy_ips = undef, | 65 Optional[Array[Stdlib::Host]] $trusted_proxy_ips = undef, |
66 Optional[Stdlib::Absolutepath] $trusted_proxy_list = undef, | 66 Optional[Stdlib::Absolutepath] $trusted_proxy_list = undef, |
67 Optional[String] $apache_version = undef, | 67 Optional[String] $apache_version = undef, |
68 ) { | 68 ) { |
69 include ::apache | 69 include apache |
70 | 70 |
71 $_apache_version = pick($apache_version, $apache::apache_version) | 71 $_apache_version = pick($apache_version, $apache::apache_version) |
72 if versioncmp($_apache_version, '2.4') < 0 { | 72 if versioncmp($_apache_version, '2.4') < 0 { |
73 fail('mod_remoteip is only available in Apache 2.4') | 73 fail('mod_remoteip is only available in Apache 2.4') |
74 } | 74 } |
102 trusted_proxy_list => $trusted_proxy_list, | 102 trusted_proxy_list => $trusted_proxy_list, |
103 } | 103 } |
104 | 104 |
105 file { 'remoteip.conf': | 105 file { 'remoteip.conf': |
106 ensure => file, | 106 ensure => file, |
107 path => "${::apache::mod_dir}/remoteip.conf", | 107 path => "${apache::mod_dir}/remoteip.conf", |
108 mode => $::apache::file_mode, | 108 mode => $apache::file_mode, |
109 content => epp('apache/mod/remoteip.conf.epp', $template_parameters), | 109 content => epp('apache/mod/remoteip.conf.epp', $template_parameters), |
110 require => Exec["mkdir ${::apache::mod_dir}"], | 110 require => Exec["mkdir ${apache::mod_dir}"], |
111 before => File[$::apache::mod_dir], | 111 before => File[$apache::mod_dir], |
112 notify => Class['apache::service'], | 112 notify => Class['apache::service'], |
113 } | 113 } |
114 } | 114 } |