Failover seems to work without root
parent
c5d35bacde
commit
e6fcff099e
@ -1,8 +1,8 @@
|
||||
primary: sync
|
||||
./failover.sh -P 192.168.56.113 -S 192.168.56.114 -H 192.168.56.113
|
||||
./failover.sh -P nagiosxi-p.princeton.edu -S nagiosxi-f.princeton.edu -H nagiosxi-p.princeton.edu
|
||||
|
||||
secondary:
|
||||
./failover.sh -P 192.168.56.113 -S 192.168.56.114 -H 192.168.56.114
|
||||
./failover.sh -P nagiosxi-p.princeton.edu -S nagiosxi-f.princeton.edu -H nagiosxi-f.princeton.edu
|
||||
|
||||
sync:
|
||||
rsync -av --stats ./ secondary:/root/princeton/failover
|
||||
rsync -av /home/nagios/bin/ nagiosxi-f.princeton.edu:/home/nagios/bin/
|
||||
|
||||
@ -0,0 +1,20 @@
|
||||
verbose () {
|
||||
echo "${color_green}$1${color_normal}"
|
||||
}
|
||||
error () {
|
||||
echo "${color_red}$1${color_normal}"
|
||||
}
|
||||
warning () {
|
||||
echo "${color_yellow}$1${color_normal}"
|
||||
}
|
||||
# check for color support
|
||||
if test -t 1; then
|
||||
# see if it supports colors...
|
||||
ncolors=$(tput colors)
|
||||
if test -n "$ncolors" && test $ncolors -ge 8; then
|
||||
color_normal="$(tput sgr0)"
|
||||
color_red="$(tput setaf 1)"
|
||||
color_green="$(tput setaf 2)"
|
||||
color_yellow="$(tput setaf 3)"
|
||||
fi
|
||||
fi
|
||||
@ -1,7 +1,7 @@
|
||||
#header {
|
||||
background: rgb(59,234,2);
|
||||
background: -moz-linear-gradient(90deg, rgba(59,234,2,1) 0%, rgba(8,124,8,1) 35%);
|
||||
background: -webkit-linear-gradient(90deg, rgba(59,234,2,1) 0%, rgba(8,124,8,1) 35%);
|
||||
background: linear-gradient(90deg, rgba(59,234,2,1) 0%, rgba(8,124,8,1) 35%);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr="#3bea02",endColorstr="#087c08",GradientType=1);
|
||||
background: rgb(0,0,255);
|
||||
background: -moz-linear-gradient(90deg, rgba(0,0,255,1) 0%, rgba(0,0,0,1) 50%);
|
||||
background: -webkit-linear-gradient(90deg, rgba(0,0,255,1) 0%, rgba(0,0,0,1) 50%);
|
||||
background: linear-gradient(90deg, rgba(0,0,255,1) 0%, rgba(0,0,0,1) 50%);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr="#0000ff",endColorstr="#000000",GradientType=1);
|
||||
}
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
#header {
|
||||
background: rgb(234,59,2);
|
||||
background: -moz-linear-gradient(90deg, rgba(234,59,2,1) 0%, rgba(121,51,11,1) 35%);
|
||||
background: -webkit-linear-gradient(90deg, rgba(234,59,2,1) 0%, rgba(121,51,11,1) 35%);
|
||||
background: linear-gradient(90deg, rgba(234,59,2,1) 0%, rgba(121,51,11,1) 35%);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr="#ea3b02",endColorstr="#79330b",GradientType=1);
|
||||
background: rgb(0,255,0);
|
||||
background: -moz-linear-gradient(90deg, rgba(0,255,0,1) 0%, rgba(0,0,0,1) 50%);
|
||||
background: -webkit-linear-gradient(90deg, rgba(0,255,0,1) 0%, rgba(0,0,0,1) 50%);
|
||||
background: linear-gradient(90deg, rgba(0,255,0,1) 0%, rgba(0,0,0,1) 50%);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr="#00ff00",endColorstr="#000000",GradientType=1);
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue