Added fixes for hestiacp for rpm installer
This commit is contained in:
@@ -23,8 +23,12 @@ send_email_report() {
|
||||
email=$(echo "$email" | cut -f 2 -d "'")
|
||||
tmpfile=$(mktemp)
|
||||
subj="$(hostname): $FTP_SYSTEM restart failed"
|
||||
service "$FTP_SYSTEM" configtest >> $tmpfile 2>&1
|
||||
service "$FTP_SYSTEM" restart >> $tmpfile 2>&1
|
||||
if [ -f /etc/redhat-release ]; then
|
||||
systemctl restart "$FTP_SYSTEM" >> $tmpfile 2>&1
|
||||
else
|
||||
service "$FTP_SYSTEM" configtest >> $tmpfile 2>&1
|
||||
service "$FTP_SYSTEM" restart >> $tmpfile 2>&1
|
||||
fi
|
||||
cat $tmpfile | $SENDMAIL -s "$subj" $email
|
||||
rm -f $tmpfile
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user