We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7c52a77 commit 5ef49eaCopy full SHA for 5ef49ea
bin/v-restart-mail
@@ -49,8 +49,17 @@ if [ -z "$MAIL_SYSTEM" ] || [ "$MAIL_SYSTEM" = 'remote' ]; then
49
exit
50
fi
51
52
-# Restart system
53
-service $MAIL_SYSTEM restart >/dev/null 2>&1
+# Restart IMAP system if present
+if [ ! -z "$IMAP_SYSTEM" ]; then
54
+ $BIN/v-restart-service $IMAP_SYSTEM > /dev/null 2>&1
55
+ if [ $? -ne 0 ]; then
56
+ send_email_report
57
+ check_result $E_RESTART "$IMAP_SYSTEM restart failed"
58
+ fi
59
+fi
60
+
61
+# Restart mail system
62
+$BIN/v-restart-service $MAIL_SYSTEM >/dev/null 2>&1
63
if [ $? -ne 0 ]; then
64
send_email_report
65
check_result $E_RESTART "$MAIL_SYSTEM restart failed"
0 commit comments