]> git.decadent.org.uk Git - dak.git/blobdiff - config/debian/dinstall.functions
Move ddaccess sync out of the locked area and background it
[dak.git] / config / debian / dinstall.functions
index a11c75e3049332c826b6b2e88daa222600aaaf26..334d5e4618f723c957b9da81876d438ecd7d7135 100644 (file)
@@ -56,7 +56,7 @@ function onerror() {
 # pushing merkels QA user, part one
 function qa1() {
     log "Telling QA user that we start dinstall"
-    ssh -2 -i ~dak/.ssh/push_merkel_qa  -o BatchMode=yes -o SetupTimeOut=90 -o ConnectTimeout=90 qa@qa.debian.org sleep 1
+    ssh -n -2 -i ~dak/.ssh/push_merkel_qa  -o BatchMode=yes -o SetupTimeOut=90 -o ConnectTimeout=90 qa@qa.debian.org sleep 1
 }
 
 # Updating various files
@@ -432,18 +432,17 @@ function mkchecksums() {
 }
 
 function mirror() {
-    local archiveroot mirrordir targetpath TRACEFILE
+    local archiveroot targetpath TRACEFILE
 
     for archive in "${public_archives[@]}"; do
         archiveroot="$(get_archiveroot "${archive}")"
-        mirrordir="${archiveroot}/../mirror"
         targetpath="${mirrordir}/${archive}"
         TRACEFILE="${archiveroot}/project/trace/ftp-master.debian.org"
         mkdir -p "${archiveroot}/project/trace/"
 
         log "Regenerating \"public\" mirror/${archive} hardlink fun"
         DATE_SERIAL=$(date +"%Y%m%d01")
-        FILESOAPLUS1=$(awk '/serial/ { print $3+1 }' ${TRACEFILE} )
+        FILESOAPLUS1=$(awk '/serial/ { print $3+1 }' ${TRACEFILE} || echo ${DATE_SERIAL} )
         if [ "$DATE_SERIAL" -gt "$FILESOAPLUS1" ]; then
             SERIAL="$DATE_SERIAL"
         else
@@ -491,12 +490,11 @@ function ddaccess() {
 function mirrorpush() {
     log "Checking the public archive copies..."
 
-    local archiveroot mirrordir targetpath
+    local archiveroot targetpath
 
     for archive in "${public_archives[@]}"; do
         log "... archive: ${archive}"
         archiveroot="$(get_archiveroot "${archive}")"
-        mirrordir="${archiveroot}/../mirror"
         targetpath="${mirrordir}/${archive}"
         cd ${targetpath}/dists