This commit is contained in:
Christoph 2018-09-08 04:34:04 +02:00
commit 684b9b35fe

View File

@ -16,6 +16,7 @@
content_type='Content-Type: text/plain;\n charset="utf-8"'
extra_admin_email=""
extra_error_email=""
## - These variables will be exportet from backup script (rcopy.sh)
@ -34,6 +35,9 @@
datum=`date +"%d.%m.%Y"`
echo -e "To:${admin_email}\n${content_type}\nSubject:Backup $company -- $datum\n$filesystem\n\ndisk label: $label\n$durations\n\n$send\n" | /usr/sbin/sendmail -F "BACKUP $company" -f $from_address $admin_email
if [[ -n "$extra_admin_email" ]]; then
echo -e "To:${extra_admin_email}\n${content_type}\nSubject:Backup $company -- $datum\n$filesystem\n\ndisk label: $label\n$durations\n\n$send\n" | /usr/sbin/sendmail -F "BACKUP $company" -f $from_address $extra_admin_email
fi
declare -i error=`grep -e"\[ERROR" $logFile | wc -l`
declare -i warning=`grep -e"\[WARN" $logFile | wc -l`