From eebf7f263d5a02b403fe157de90dee349cab640c Mon Sep 17 00:00:00 2001 From: Silvan Calarco Date: Mon, 10 Sep 2012 17:51:11 +0200 Subject: [PATCH] autoport cron: fix some log paths with the ones used by current autodist/autoport --- etc/cron.hourly/65-autoport | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/etc/cron.hourly/65-autoport b/etc/cron.hourly/65-autoport index 50d81b4..a1c39f0 100755 --- a/etc/cron.hourly/65-autoport +++ b/etc/cron.hourly/65-autoport @@ -43,14 +43,14 @@ for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do fi if [ "${AUTOPORT_CHROOT[$i]}" ]; then - LOGFILE="/var/autodist/log/autoport-chroot-${AUTOPORT_CHROOT[$i]}.log" - LASTLOGFILE="/var/autodist/log/autoport-chroot-${AUTOPORT_CHROOT[$i]}-last.log" + LOGFILE="/var/autodist/log/autoport-chroot-$r-${AUTOPORT_CHROOT[$i]}.log" + LASTLOGFILE="/var/autodist/log/autoport-chroot-$r-${AUTOPORT_CHROOT[$i]}-last.log" elif [ "${AUTOPORT_NATIVE[$i]}" ]; then LOGFILE="/var/autodist/log/autoport-native-$r-${AUTOPORT_ARCH[$i]}.log" LASTLOGFILE="/var/autodist/log/autoport-native-$r-${AUTOPORT_ARCH[$i]}-last.log" elif [ "${AUTOPORT_CROSS[$i]}" ]; then - LOGFILE="/var/autodist/log/autoport-cross-${AUTOPORT_CROSS[$i]}.log" - LASTLOGFILE="/var/autodist/log/autoport-cross-${AUTOPORT_CROSS[$i]}-last.log" + LOGFILE="/var/autodist/log/autoport-cross-$r-${AUTOPORT_CROSS[$i]}.log" + LASTLOGFILE="/var/autodist/log/autoport-cross-$r-${AUTOPORT_CROSS[$i]}-last.log" else continue fi @@ -73,7 +73,7 @@ for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do ln -s /bin/true /var/autoport/$a/sbin/service $CMD_PREFIX /usr/sbin/chroot /var/autoport/$a su -l ${AUTOPORT_CHROOT_USER[$i]} -c "autoport -b -r $r" >> $LOGFILE mv /var/autoport/$a/sbin/service.autoport /var/autoport/$a/sbin/service - cat /var/autoport/$a/home/${AUTOPORT_CHROOT_USER[$i]}/.autoport/${AUTOPORT_ARCH[$i]}/${r}.log >> $LOGFILE + cat /var/autoport/$a/home/${AUTOPORT_CHROOT_USER[$i]}/.autoport/${AUTOPORT_ARCH[$i]}/$r-current.log >> $LOGFILE fi if [ "${AUTOPORT_NATIVE[$i]}" ]; then @@ -84,7 +84,7 @@ for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do LANG=C smart upgrade -y >> $LOGFILE echo "= Working on $r($a) in native mode" >> $LOGFILE su -l autodist -c "autoport -b -r $r" >> $LOGFILE - cat /var/autodist/.autoport/$a/log >> $LOGFILE + cat /var/autodist/.autoport/$a/$r-current.log >> $LOGFILE fi if [ "${AUTOPORT_CROSS[$i]}" ]; then @@ -92,7 +92,7 @@ for i in `seq 0 ${#AUTOPORT_ARCH[*]}`; do [[ "`/usr/bin/tty`" != "not a tty" ]] && echo "Working on $r($a) in cross-platform mode" echo "= Working on $r($a) in cross-platform mode" >> $LOGFILE su -l autodist -c "autoport -b -x $a -r $r" >> $LOGFILE - cat /var/autodist/.autoport/$a/log >> $LOGFILE + cat /var/autodist/.autoport/$a/$r-current.log >> $LOGFILE fi echo "- Autoport end at `date`" >> $LOGFILE