From 58b2d63c46d70d0eb08e5c1f7dd3d1a4ec76ca9e Mon Sep 17 00:00:00 2001 From: Michael Prokop Date: Tue, 24 Feb 2009 01:28:30 +0100 Subject: [PATCH] buildd: send_mail() - do not add /var/log/grml-buildd.stdout by default --- buildd/execute.sh | 4 ++-- buildd/functions.sh | 5 +++-- debian/changelog | 3 ++- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/buildd/execute.sh b/buildd/execute.sh index 86942e4..cb0ac90 100755 --- a/buildd/execute.sh +++ b/buildd/execute.sh @@ -8,7 +8,7 @@ . /usr/share/grml-live/buildd/functions.sh || exit 1 # execute main grml-live -grml_live_run +grml_live_run || create_logs # store logs on remote server upload_logs @@ -17,7 +17,7 @@ upload_logs iso_details # create logs for adding to mail, but only if it fails -send_mail -e +send_mail # move the ISO to final destination store_iso diff --git a/buildd/functions.sh b/buildd/functions.sh index 226b372..b658143 100755 --- a/buildd/functions.sh +++ b/buildd/functions.sh @@ -77,6 +77,7 @@ grml_live_run() { RC_INFO=success else RC_INFO=error + return 1 fi } @@ -104,7 +105,7 @@ iso_details() { # send status mail: send_mail() { - # create logs only if using 'send_mail -e' + # create logs if using 'send_mail -e' [ "$1" = "-e" ] && create_logs # attach logs only if we have some: [ -r "$ATTACHMENT" ] && MUTT_ATTACH="-a $ATTACHMENT" || MUTT_ATTACH='' @@ -139,7 +140,7 @@ See attached files: /var/log/grml-buildd.stderr /var/log/grml-buildd.stdout $ATTACHMENT EOF " | \ - mutt -s "$SCRIPTNAME [${DATE}] - $RC_INFO" -a /var/log/grml-buildd.stderr -a /var/log/grml-buildd.stdout $MUTT_ATTACH "$RECIPIENT" + mutt -s "$SCRIPTNAME [${DATE}] - $RC_INFO" -a /var/log/grml-buildd.stderr $MUTT_ATTACH "$RECIPIENT" } # make sure we store the final iso: diff --git a/debian/changelog b/debian/changelog index fdc371b..c81420b 100644 --- a/debian/changelog +++ b/debian/changelog @@ -6,8 +6,9 @@ grml-live (0.9.10) unstable; urgency=low we would get: "mkisofs: Volume ID string too long (cur. XX max. 32 chars)." - add buildd/execute.sh to further simplify buildd/*.sh setup + - send_mail(): do not append /var/log/grml-buildd.stdout by default - -- Michael Prokop Tue, 24 Feb 2009 00:12:01 +0100 + -- Michael Prokop Tue, 24 Feb 2009 01:27:19 +0100 grml-live (0.9.9) unstable; urgency=low -- 2.1.4