Merge pull request #454 from enovance/fix-haproxy
loadbalancer: manage HAproxy on MASTER node
This commit is contained in:
@@ -231,11 +231,17 @@ class cloud::loadbalancer(
|
||||
}
|
||||
|
||||
# Ensure Keepalived is started before HAproxy to avoid binding errors.
|
||||
# HAproxy is managed by Keepalived.
|
||||
class { 'keepalived': } ->
|
||||
class { 'haproxy':
|
||||
service_manage => false
|
||||
}
|
||||
# Still allow HAproxy to start
|
||||
if ($::osfamily == 'Debian') {
|
||||
file { '/etc/default/haproxy':
|
||||
content => 'ENABLED=1',
|
||||
before => Service['haproxy'],
|
||||
}
|
||||
}
|
||||
|
||||
keepalived::vrrp_script { 'haproxy':
|
||||
name_is_process => true
|
||||
|
||||
Reference in New Issue
Block a user