8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
# File 'modules/haproxy/manifests/confd_site.pp', line 8
define haproxy::confd_site (
Wmflib::Ensure $ensure,
String $content,
Array[String[1]] $watch_keys,
String $prefix = '',
) {
$safe_title = regsubst($title, '[^a-zA-Z0-9]', '_', 'G')
confd::file { "/etc/haproxy/conf.d/${safe_title}.cfg":
ensure => $ensure,
content => $content,
watch_keys => $watch_keys,
prefix => $prefix,
check => '/usr/sbin/haproxy -c -V -f /etc/haproxy/haproxy.cfg -f',
reload => '/usr/bin/systemctl reload haproxy.service',
before => Service['haproxy'],
}
}
|