Add ns02.home.foo.sh host

This commit is contained in:
Timo Makinen 2020-09-03 17:59:43 +00:00
parent 69c17d7e12
commit c9f3b7d0b7
5 changed files with 81 additions and 0 deletions

View file

@ -0,0 +1,32 @@
init-state auto
if_carp_up="carp157.link.up"
if_carp_down="carp157.link.down"
state auto {
if $if_carp_up {
set-state master
}
if $if_carp_down {
set-state backup
}
}
state master {
init {
run "route delete default && route add default 37.16.96.145"
}
if $if_carp_down {
set-state backup
}
}
state backup {
init {
run "route delete default && route add default 172.20.20.1"
}
if $if_carp_up {
set-state master
}
}