Removing nginx restart lock

This commit is contained in:
myvesta 2018-04-26 18:46:00 +02:00 committed by GitHub
commit a3a2daa4cd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -53,7 +53,7 @@ fi
if [ "$1" = 'background' ]; then if [ "$1" = 'background' ]; then
# Restart system # Restart system
sleep 1 sleep 1
rm /tmp/restart-nginx # rm /tmp/restart-nginx
service $PROXY_SYSTEM restart >/dev/null 2>&1 service $PROXY_SYSTEM restart >/dev/null 2>&1
if [ $? -ne 0 ]; then if [ $? -ne 0 ]; then
send_email_report send_email_report
@ -68,9 +68,9 @@ if [ "$1" = 'background' ]; then
exit; exit;
fi fi
if [ -f "/tmp/restart-nginx" ]; then # if [ -f "/tmp/restart-nginx" ]; then
exit; # exit;
fi # fi
service $PROXY_SYSTEM reload service $PROXY_SYSTEM reload
if [ $? -ne 0 ]; then if [ $? -ne 0 ]; then
@ -78,7 +78,7 @@ if [ $? -ne 0 ]; then
check_result $E_RESTART "$PROXY_SYSTEM reload failed" check_result $E_RESTART "$PROXY_SYSTEM reload failed"
fi fi
touch /tmp/restart-nginx # touch /tmp/restart-nginx
nohup $BIN/v-restart-proxy 'background' &>/dev/null & nohup $BIN/v-restart-proxy 'background' &>/dev/null &
#----------------------------------------------------------# #----------------------------------------------------------#