X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;f=config%2Fdebian%2Fcommon;h=9fd9838359e9786c223d6111ef0a9aac12ec7684;hb=f0bfd37e7286156598d79b53501ebe2000bb7924;hp=5d39718a47ece6d4884dfc35e3094b1492971501;hpb=0872b2e0b78670c91fd2bf0bda52e5761e079820;p=dak.git diff --git a/config/debian/common b/config/debian/common index 5d39718a..9fd98383 100644 --- a/config/debian/common +++ b/config/debian/common @@ -15,7 +15,7 @@ function log () { function log_error () { log "$@" if [ -z "${MAILTO}" ]; then - echo "$@" | mail -e -s "[$PROGRAM@$(hostname -s)] ERROR [$$]" ${MAILTO} + echo "$@" | mail -a "X-Debian: DAK" -e -s "[$PROGRAM@$(hostname -s)] ERROR [$$]" ${MAILTO} -- -F "Debian FTP Masters" -f ftpmaster@ftp-master.debian.org fi } @@ -78,9 +78,9 @@ function sync_debbugs () { # sync with debbugs echo "--" >> $report timestamp=$(date "+%Y-%m-%d-%H:%M") - mkdir -p $queuedir/${timestamp} + mkdir -p $queuedir/bts_version_track_archive/${timestamp} rsync -aq $queuedir/bts_version_track/ $queuedir/bts_version_track_archive/${timestamp} - rmdir --ignore-fail-on-non-empty $queuedir/${timestamp} # remove if empty. + rmdir --ignore-fail-on-non-empty $queuedir/bts_version_track_archive/${timestamp} # remove if empty. rsync -aq -e "ssh -o Batchmode=yes -o ConnectTimeout=30 -o SetupTimeout=30" --remove-source-files $queuedir/bts_version_track/ bugs-sync:/org/bugs.debian.org/versions/queue/ftp-master/ 2>/dev/null && touch $lockdir/synced_bts_version || true NOW=$(date +%s) TSTAMP=$(stat -c %Y $lockdir/synced_bts_version) @@ -89,3 +89,14 @@ function sync_debbugs () { log "Kids, you tried your best and you failed miserably. The lesson is, never try. (Homer Simpson)" fi } + +function reports() { + # Send a report on NEW/BYHAND packages + log "Nagging ftpteam about NEW/BYHAND packages" + dak queue-report | mail -a "X-Debian: DAK" -e -s "NEW and BYHAND on $(date +%D)" ftpmaster@ftp-master.debian.org -- -F "Debian FTP Masters" -f ftpmaster@ftp-master.debian.org + # and one on crufty packages + log "Sending information about crufty packages" + dak cruft-report > $webdir/cruft-report-daily.txt + dak cruft-report -s experimental >> $webdir/cruft-report-daily.txt + cat $webdir/cruft-report-daily.txt | mail -a "X-Debian: DAK" -e -s "Debian archive cruft report for $(date +%D)" ftpmaster@ftp-master.debian.org -- -F "Debian FTP Masters" -f ftpmaster@ftp-master.debian.org +}