summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHolger Levsen <holger@layer-acht.org>2015-09-22 23:41:32 +0200
committerHolger Levsen <holger@layer-acht.org>2015-09-22 23:41:32 +0200
commitd91692119e074964a8b76ff1394b22600b71b387 (patch)
treefc14fa54765d7cee6efa2716dcae79251474ef33
parent34864370448ad18592206736bb531f34fd556e20 (diff)
downloadjenkins.debian.net-d91692119e074964a8b76ff1394b22600b71b387.tar.xz
reproducible: more randomly select a package to build to better avoid race conditions (this commit should probably be reverted / improved one day
-rwxr-xr-xbin/reproducible_build.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/bin/reproducible_build.sh b/bin/reproducible_build.sh
index 22df05aa..827fac54 100755
--- a/bin/reproducible_build.sh
+++ b/bin/reproducible_build.sh
@@ -377,7 +377,7 @@ choose_package () {
FROM schedule AS sch JOIN sources AS s ON sch.package_id=s.id
WHERE sch.date_build_started = ''
AND s.architecture='$ARCH'
- ORDER BY date_scheduled LIMIT 1")
+ ORDER BY date_scheduled LIMIT 5"|sort -R|head -1)
SUITE=$(echo $RESULT|cut -d "|" -f1)
SRCPKGID=$(echo $RESULT|cut -d "|" -f2)
SRCPACKAGE=$(echo $RESULT|cut -d "|" -f3)