haproxy-wi/app/scripts/ansible/roles/keepalived/templates/add_vrrp.conf.j2

22 lines
462 B
Plaintext
Raw Normal View History

vrrp_instance VI_{{IP}} {
2019-11-06 15:15:41 +00:00
state {{MASTER}}
interface {% if MASTER == 'MASTER' %}{{ETH}} {% else %} {{ETH_SLAVE}} {% endif %}
virtual_router_id {{ router_id }}
priority {% if RETURN_TO_MASTER == 1 and MASTER == 'MASTER' %}152{% elif MASTER == 'MASTER' and RETURN_TO_MASTER == 0 %}102{% else %}101{%endif%}
2019-11-06 15:15:41 +00:00
track_script {
chk_haproxy
}
advert_int 1
authentication {
auth_type PASS
auth_pass VerySecretPass2!
}
virtual_ipaddress {
{{IP}}
}
}