Don't use a default reason when downing a portal.
This commit is contained in:
parent
5473b8475a
commit
e2171b5a89
|
@ -12,7 +12,11 @@ do
|
|||
done
|
||||
delay=${delay:-0} # default to no delay
|
||||
timeout=${timeout:-300} # default timeout is 300s
|
||||
reason=${reason:-"disabled manually"}
|
||||
|
||||
if [[ -z $reason ]]; then
|
||||
echo "Please provide a reason for disabling the portal (use '-r <reason>')."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
countdown() {
|
||||
local secs=$1
|
||||
|
@ -26,7 +30,7 @@ countdown() {
|
|||
# delay disabling the portal
|
||||
countdown $delay
|
||||
|
||||
# stop healh-check so the server is taken our of load balancer
|
||||
# stop health-check so the server is taken our of load balancer
|
||||
docker exec health-check cli disable $reason
|
||||
|
||||
# then wait 5 minutes for the load balancer to propagate the dns records
|
||||
|
|
Reference in New Issue