Search
j0ke.net Open Build Service
>
Projects
>
server:backup
>
automysqlbackup
> automysqlbackup.sh.mailfrom.patch
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File automysqlbackup.sh.mailfrom.patch of Package automysqlbackup (Revision 6)
Currently displaying revision
6
,
show latest
--- automysqlbackup.sh.2.5.orig 2009-05-23 17:58:36.000000000 +0200 +++ automysqlbackup.sh.2.5 2009-05-23 19:34:20.000000000 +0200 @@ -53,6 +53,8 @@ # Email Address to send mail to? (user@domain.com) MAILADDR="user@domain.com" +# Email Address to send mail from? (root@host.tld) +FROMADDR="automysqlbackup@`hostname -f`" # ============================================================ # === ADVANCED OPTIONS ( Read the doc's below for details )=== @@ -644,21 +646,21 @@ BACKUPFILES=`echo "$BACKUPFILES" | sed -e "s# # -a #g"` #enable multiple attachments mutt -s "$ERRORNOTE MySQL Backup Log and SQL Files for $HOST - $DATE" $BACKUPFILES $MAILADDR < $LOGFILE #send via mutt else - cat "$LOGFILE" | mail -s "WARNING! - MySQL Backup exceeds set maximum attachment size on $HOST - $DATE" $MAILADDR + cat "$LOGFILE" | mail -r ${FROMADDR} -s "WARNING! - MySQL Backup exceeds set maximum attachment size on $HOST - $DATE" $MAILADDR fi elif [ "$MAILCONTENT" = "log" ] then - cat "$LOGFILE" | mail -s "MySQL Backup Log for $HOST - $DATE" $MAILADDR + cat "$LOGFILE" | mail -r ${FROMADDR} -s "MySQL Backup Log for $HOST - $DATE" $MAILADDR if [ -s "$LOGERR" ] then - cat "$LOGERR" | mail -s "ERRORS REPORTED: MySQL Backup error Log for $HOST - $DATE" $MAILADDR + cat "$LOGERR" | mail -r ${FROMADDR} -s "ERRORS REPORTED: MySQL Backup error Log for $HOST - $DATE" $MAILADDR fi elif [ "$MAILCONTENT" = "quiet" ] then if [ -s "$LOGERR" ] then - cat "$LOGERR" | mail -s "ERRORS REPORTED: MySQL Backup error Log for $HOST - $DATE" $MAILADDR - cat "$LOGFILE" | mail -s "MySQL Backup Log for $HOST - $DATE" $MAILADDR + cat "$LOGERR" | mail -r ${FROMADDR} -s "ERRORS REPORTED: MySQL Backup error Log for $HOST - $DATE" $MAILADDR + cat "$LOGFILE" | mail -r ${FROMADDR} -s "MySQL Backup Log for $HOST - $DATE" $MAILADDR fi else if [ -s "$LOGERR" ]