Skip to content

Instantly share code, notes, and snippets.

@thresheek
Created August 24, 2017 11:27
Show Gist options
  • Save thresheek/15842319d330d875c0f712ca5139a42d to your computer and use it in GitHub Desktop.
Save thresheek/15842319d330d875c0f712ca5139a42d to your computer and use it in GitHub Desktop.
global_defs {
vrrp_version 3
}
vrrp_script chk_manual_failover {
script "/usr/lib/keepalived/nginx-ha-manual-failover"
interval 10
weight 50
}
vrrp_script chk_nginx_service {
script "/usr/lib/keepalived/nginx-ha-check"
interval 3
weight 50
}
vrrp_instance VI_1 {
interface eth0
priority 101
virtual_router_id 51
advert_int 1
accept
unicast_src_ip 192.168.128.111
unicast_peer {
192.168.128.112
192.168.128.114
}
virtual_ipaddress {
10.0.0.33
}
track_script {
chk_nginx_service
chk_manual_failover
}
notify "/usr/lib/keepalived/nginx-ha-notify"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment