32 lines
499 B
Plaintext
32 lines
499 B
Plaintext
global_defs {
|
|
router_id {{ pg_hostname }}
|
|
}
|
|
|
|
vrrp_script chk_nginx {
|
|
script "killall -0 nginx"
|
|
interval 2
|
|
}
|
|
|
|
vrrp_instance nos {
|
|
virtual_router_id {{ virtual_router_id }}
|
|
|
|
# for electing MASTER, highest priority wins.
|
|
priority 100
|
|
state BACKUP
|
|
nopreempt
|
|
|
|
interface {{ interface }}
|
|
|
|
virtual_ipaddress {
|
|
{{ virtual_ip }} dev {{ interface }} label {{ interface }}:1
|
|
}
|
|
track_script {
|
|
chk_nginx
|
|
}
|
|
authentication {
|
|
auth_type PASS
|
|
auth_pass keepaliv
|
|
}
|
|
}
|
|
|