From 049f28b1555a87c6129dade7f57ab9ce7cc4237f Mon Sep 17 00:00:00 2001 From: Paul Spooren Date: Sat, 9 Apr 2022 13:40:50 +0200 Subject: [PATCH] openwrt: add missing RUN to node_cleanup Signed-off-by: Paul Spooren --- bin/reproducible_openwrt.sh | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/bin/reproducible_openwrt.sh b/bin/reproducible_openwrt.sh index cf20f13e1..51d2dc653 100755 --- a/bin/reproducible_openwrt.sh +++ b/bin/reproducible_openwrt.sh @@ -42,7 +42,8 @@ node_debug() { # only called direct on a remote build node node_cleanup_tmpdirs() { - export TMPBUILDDIR=$1 + export RUN=$1 + export TMPBUILDDIR=$2 cd # (very simple) check we are deleting the right stuff if [ "${TMPBUILDDIR:0:23}" != "/srv/workspace/chroots/" ] || [ ${#TMPBUILDDIR} -le 23 ] ; then @@ -82,8 +83,8 @@ master_cleanup_tmpdirs() { rsync -av "$GENERIC_NODE2:$TMPBUILDDIR/build_logs.tar.xz" "$WORKSPACE/results/build_logs_b2.tar.xz" || true fi - $SSHN1 "reproducible_openwrt" node node_cleanup_tmpdirs "$TMPBUILDDIR" || true - $SSHN2 "reproducible_openwrt" node node_cleanup_tmpdirs "$TMPBUILDDIR" || true + $SSHN1 "reproducible_openwrt" node node_cleanup_tmpdirs "b1" "$TMPBUILDDIR" || true + $SSHN2 "reproducible_openwrt" node node_cleanup_tmpdirs "b2" "$TMPBUILDDIR" || true cd # (very simple) check we are deleting the right stuff @@ -473,7 +474,7 @@ build_two_times() { rsync -av "$GENERIC_NODE1:$TMPBUILDDIR/$RUN/" "$RESULTSDIR/$RUN/" rsync -av "$GENERIC_NODE1:$TMPBUILDDIR/build_logs.tar.xz" "$WORKSPACE/results/build_logs_b1.tar.xz" rsync -av "$GENERIC_NODE1:$TMPBUILDDIR/toolchain.html" "$RESULTSDIR/toolchain.html" - $SSHN1 "reproducible_openwrt" node node_cleanup_tmpdirs "$TMPBUILDDIR" + $SSHN1 "reproducible_openwrt" node node_cleanup_tmpdirs "$RUN" "$TMPBUILDDIR" ## second run local RUN=b2 @@ -482,7 +483,7 @@ build_two_times() { # rsync back logs and images rsync -av "$GENERIC_NODE2:$TMPBUILDDIR/$RUN/" "$RESULTSDIR/$RUN/" rsync -av "$GENERIC_NODE2:$TMPBUILDDIR/build_logs.tar.xz" "$WORKSPACE/results/build_logs_b2.tar.xz" - $SSHN2 "reproducible_openwrt" node node_cleanup_tmpdirs "$TMPBUILDDIR" + $SSHN2 "reproducible_openwrt" node node_cleanup_tmpdirs "$RUN" "$TMPBUILDDIR" } -- GitLab