check_result function

This commit is contained in:
Serghey Rodin 2015-10-28 16:34:41 +02:00
commit 91a804c1c8
66 changed files with 204 additions and 404 deletions

View file

@ -73,22 +73,16 @@ fi
# Vesta #
#----------------------------------------------------------#
# Restart web server
# Restarting system services
if [ "$restart" != 'no' ]; then
$BIN/v-restart-web
if [ $? -ne 0 ]; then
exit $E_RESTART
fi
check_result $? "Web restart failed" >/dev/null
$BIN/v-restart-dns
if [ $? -ne 0 ]; then
exit $E_RESTART
fi
check_result $? "DNS restart failed" >/dev/null
$BIN/v-restart-cron
if [ $? -ne 0 ]; then
exit $E_RESTART
fi
check_result $? "Cron restart failed" >/dev/null
fi
# Changing suspend value