diff --git a/conf/logrotate.conf.sample b/conf/logrotate.conf.sample index ca90e74..afb08bb 100644 --- a/conf/logrotate.conf.sample +++ b/conf/logrotate.conf.sample @@ -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`