]> git.decadent.org.uk Git - dak.git/blobdiff - cron.daily
2005-01-14 Anthony Towns <ajt@debian.org> * kelly: when UNACCEPTing, don't double...
[dak.git] / cron.daily
index 59bf12a8beed5c57e0ee31527427bd2da1f87f25..5cb1cebd0bb94459a5e997d54dbfad6ad9f00e7a 100755 (executable)
@@ -3,10 +3,10 @@
 # Executed daily via cron, out of troup's crontab.
 
 set -e
-export SCRIPTVARS=/org/ftp.debian.org/scripts/masterfiles/vars
+export SCRIPTVARS=/org/ftp.debian.org/katie/vars
 . $SCRIPTVARS
 
-##### 
+################################################################################
 
 echo Archive maintenance started at $(date +%X)
 
@@ -26,24 +26,22 @@ ending at about 15:30.  This file is then removed.
 You should not mirror the archive during this period.
 EOF
 
-##### 
+################################################################################
 
-TERM=vt100 update-bugdoctxt
+echo "Creating pre-daily-cron-job backup of projectb database..."
+pg_dump projectb > /org/ftp.debian.org/backup/dump_$(date +%Y.%m.%d-%H:%M:%S)
 
-##### 
+################################################################################
 
-pg_dump > FIXME
+update-bugdoctxt
+update-mirrorlists
+update-mailingliststxt
 
-##### 
+################################################################################
 
-# temporary hack to work around the lack of an apt-utils package
-export PYTHONPATH=$PYTHONPATH:/org/ftp.debian.org/scripts/apt/build/bin/
-export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/org/ftp.debian.org/scripts/apt/build/bin/
-export PATH=$PATH:/org/ftp.debian.org/scripts/apt/build/bin/
-
-cd $incoming
+cd $accepted
 rm -f REPORT
-dak-install -pak *.changes | direport | tee REPORT | \
+kelly -pa *.changes | tee REPORT | \
      mail -s "Install for $(date +%D)" ftpmaster@ftp-master.debian.org
 chgrp debadmin REPORT
 chmod 664 REPORT
@@ -51,21 +49,68 @@ chmod 664 REPORT
 cd $masterdir
 symlinks -d -r $ftpdir
 
+cd $masterdir
+jenna
+
+# Generate override files
+cd $overridedir
+denise
+
+# Update task overrides for testing and unstable
+# [JT 2004-02-04 disabled; copying in by hand for now]
+#cat $extoverridedir/task | perl -ne 'print if /^\S+\sTask\s\S+(,\s*\S+)*$/;' > override.sarge.extra.main
+#cat $extoverridedir/task | perl -ne 'print if /^\S+\sTask\s\S+(,\s*\S+)*$/;' > override.sid.extra.main
+
+# FIXME
+rm -f override.potato.all3 override.sid.all3
+for i in main contrib non-free; do cat override.potato.$i >> override.potato.all3; done
+for i in main contrib non-free main.debian-installer; do cat override.sid.$i >> override.sid.all3; done
+
+# Generate Packages and Sources files
 cd $masterdir
 apt-ftparchive generate apt.conf
-dak-mkmaintainers
+# Generate Release files
+ziyi
+
+# Clean out old packages
+rhona
+shania
+
+mkmaintainers
 copyoverrides
 mklslar
 mkchecksums
 
-# [JT] temporary hack to make the buildd daemons and proposed-updates get along
-pushd /org/ftp.debian.org/ftp/dists/proposed-updates
-/home/troup/katie/drow *.dsc
-popd
-
 rm -f $NOTICE
 echo Archive maintenance finished at $(date +%X)
 
+################################################################################
+
+echo "Creating post-daily-cron-job backup of projectb database..."
+POSTDUMP=/org/ftp.debian.org/backup/dump_$(date +%Y.%m.%d-%H:%M:%S)
+pg_dump projectb > $POSTDUMP
+(cd /org/ftp.debian.org/backup; ln -sf $POSTDUMP current)
+
+################################################################################
+
+# Vacuum the database
+echo "VACUUM; VACUUM ANALYZE;" | psql projectb 2>&1 | grep -v "^NOTICE:  Skipping.*only table owner can VACUUM it$"
+
+################################################################################
+
+# Send a report on NEW/BYHAND packages
+helena | mail -e -s "NEW and BYHAND on $(date +%D)" ftpmaster@ftp-master.debian.org
+# and one on crufty packages
+rene | mail -e -s "rene run for $(date +%D)" ftpmaster@ftp-master.debian.org
+
+################################################################################
+
+# Run billie
+
+time billie
+
+################################################################################
+
 ulimit -m 90000 -d 90000 -s 10000 -v 90000
 
 run-parts --report /org/ftp.debian.org/scripts/distmnt