summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHolger Levsen <holger@layer-acht.org>2015-12-16 14:39:59 +0100
committerHolger Levsen <holger@layer-acht.org>2015-12-16 14:39:59 +0100
commitd2478fbb8818ac2f4bc09e77ad5353f322e3607b (patch)
tree1e477308acd13527ddd982a15849e5820632448c
parent97c2469c69f3533aef3160b27c796713c69d2f2e (diff)
downloadjenkins.debian.net-d2478fbb8818ac2f4bc09e77ad5353f322e3607b.tar.xz
always use mktemp with '-t -XXXX'
-rwxr-xr-xbin/common-functions.sh2
-rwxr-xr-xbin/find_dpkg_trigger_cycles.sh2
-rwxr-xr-xbin/live-build.sh2
-rwxr-xr-xbin/reproducible_build.sh2
-rwxr-xr-xbin/reproducible_build_archlinux_pkg.sh2
-rwxr-xr-xbin/reproducible_build_rpm.sh2
-rwxr-xr-xbin/reproducible_coreboot.sh4
-rwxr-xr-xbin/reproducible_freebsd.sh2
-rwxr-xr-xbin/reproducible_netbsd.sh4
-rwxr-xr-xbin/reproducible_openwrt.sh4
-rwxr-xr-xupdate_jdn.sh2
11 files changed, 14 insertions, 14 deletions
diff --git a/bin/common-functions.sh b/bin/common-functions.sh
index b79c5381..f27dac70 100755
--- a/bin/common-functions.sh
+++ b/bin/common-functions.sh
@@ -107,7 +107,7 @@ publish_changes_to_userContent() {
fi
VERSION=$(basename $CHANGES | cut -d "_" -f2)
TARGET="/var/lib/jenkins/userContent/$SRCPKG"
- NEW_CONTENT=$(mktemp -d)
+ NEW_CONTENT=$(mktemp -d -t new-content-XXXXXXXX)
for DEB in $(dcmd --deb $CHANGES) ; do
dpkg --extract $DEB ${NEW_CONTENT} 2>/dev/null
done
diff --git a/bin/find_dpkg_trigger_cycles.sh b/bin/find_dpkg_trigger_cycles.sh
index 6a2cd0d8..1e9736be 100755
--- a/bin/find_dpkg_trigger_cycles.sh
+++ b/bin/find_dpkg_trigger_cycles.sh
@@ -170,7 +170,7 @@ curl --retry 3 --retry-delay 10 --globoff "http://binarycontrol.debian.net/?q=&p
| sort \
| while read pkg url; do
echo "working on $pkg..." >&2
- tmpdir=`mktemp -d --tmpdir="$scratch"`
+ tmpdir=`mktemp -d --tmpdir="$scratch" -t dpkg-trigger-cycles-curl-XXXXXXXX`
# curl is allowed to fail with exit status 23 because we want to stop
# downloading immediately after control.tar.gz has been extracted
( curl --retry 3 --retry-delay 10 --location --silent "$url" || [ "$?" -eq 23 ] || ( echo "curl failed">&2 && exec /srv/jenkins/bin/abort.sh ) ) \
diff --git a/bin/live-build.sh b/bin/live-build.sh
index 3082db69..116f17aa 100755
--- a/bin/live-build.sh
+++ b/bin/live-build.sh
@@ -11,7 +11,7 @@ cleanup_all() {
sudo rm -rf --one-file-system $TMPDIR
}
-TMPDIR=$(mktemp --tmpdir=/srv/live-build -d)
+TMPDIR=$(mktemp --tmpdir=/srv/live-build -d -t live-build-XXXXXXXX)
cd $TMPDIR
trap cleanup_all INT TERM EXIT
diff --git a/bin/reproducible_build.sh b/bin/reproducible_build.sh
index 7377335e..338c2076 100755
--- a/bin/reproducible_build.sh
+++ b/bin/reproducible_build.sh
@@ -715,7 +715,7 @@ build_rebuild() {
# below is what controls the world
#
-TMPDIR=$(mktemp --tmpdir=/srv/reproducible-results -d) # where everything actually happens
+TMPDIR=$(mktemp --tmpdir=/srv/reproducible-results -d -t rbuild-debian-XXXXXXXX) # where everything actually happens
trap cleanup_all INT TERM EXIT
cd $TMPDIR
diff --git a/bin/reproducible_build_archlinux_pkg.sh b/bin/reproducible_build_archlinux_pkg.sh
index 0dab2b36..b60aaf8b 100755
--- a/bin/reproducible_build_archlinux_pkg.sh
+++ b/bin/reproducible_build_archlinux_pkg.sh
@@ -213,7 +213,7 @@ remote_build() {
# below is what controls the world
#
-TMPDIR=$(mktemp --tmpdir=/srv/reproducible-results -d) # where everything actually happens
+TMPDIR=$(mktemp --tmpdir=/srv/reproducible-results -d -t rbuild-archlinux-XXXXXXXX) # where everything actually happens
trap cleanup_all INT TERM EXIT
cd $TMPDIR
diff --git a/bin/reproducible_build_rpm.sh b/bin/reproducible_build_rpm.sh
index 6b12d298..bc06f605 100755
--- a/bin/reproducible_build_rpm.sh
+++ b/bin/reproducible_build_rpm.sh
@@ -169,7 +169,7 @@ remote_build() {
# below is what controls the world
#
-TMPDIR=$(mktemp --tmpdir=/srv/reproducible-results -d) # where everything actually happens
+TMPDIR=$(mktemp --tmpdir=/srv/reproducible-results -d -t rbuild-rpm-XXXXXXXX) # where everything actually happens
trap cleanup_all INT TERM EXIT
cd $TMPDIR
diff --git a/bin/reproducible_coreboot.sh b/bin/reproducible_coreboot.sh
index 7c8fe40f..d04d08c5 100755
--- a/bin/reproducible_coreboot.sh
+++ b/bin/reproducible_coreboot.sh
@@ -41,8 +41,8 @@ save_coreboot_results() {
#
# main
#
-TMPBUILDDIR=$(mktemp --tmpdir=/srv/workspace/chroots/ -d -t coreboot-XXXXXXXX) # used to build on tmpfs
-TMPDIR=$(mktemp --tmpdir=/srv/reproducible-results -d) # accessable in schroots, used to compare results
+TMPBUILDDIR=$(mktemp --tmpdir=/srv/workspace/chroots/ -d -t rbuild-coreboot-build-XXXXXXXX) # used to build on tmpfs
+TMPDIR=$(mktemp --tmpdir=/srv/reproducible-results -d -t rbuild-coreboot-results-XXXXXXXX) # accessable in schroots, used to compare results
DATE=$(date -u +'%Y-%m-%d')
START=$(date +'%s')
trap cleanup_tmpdirs INT TERM EXIT
diff --git a/bin/reproducible_freebsd.sh b/bin/reproducible_freebsd.sh
index 70524d04..a66504d8 100755
--- a/bin/reproducible_freebsd.sh
+++ b/bin/reproducible_freebsd.sh
@@ -96,7 +96,7 @@ for FREEBSD_TARGET in ${FREEBSD_TARGETS} ;do
RSCP="scp -r freebsd-jenkins.debian.net"
TMPBUILDDIR=/usr/src
$RSSH 'sudo rm -rf /usr/src ; sudo mkdir /usr/src ; sudo chown jenkins /usr/src' ### this is tmpfs on linux, we should move this to tmpfs on FreeBSD too
- TMPDIR=$($RSSH 'TMPDIR=/srv/reproducible-results mktemp -d') # used to compare results
+ TMPDIR=$($RSSH 'TMPDIR=/srv/reproducible-results mktemp -d -t rbuild-freebsd-XXXXXXXX') # used to compare results
DATE=$(date -u +'%Y-%m-%d')
START=$(date +'%s')
trap cleanup_tmpdirs INT TERM EXIT
diff --git a/bin/reproducible_netbsd.sh b/bin/reproducible_netbsd.sh
index 4b5da468..939fea36 100755
--- a/bin/reproducible_netbsd.sh
+++ b/bin/reproducible_netbsd.sh
@@ -36,8 +36,8 @@ save_netbsd_results() {
#
# main
#
-TMPBUILDDIR=$(mktemp --tmpdir=/srv/workspace/chroots/ -d -t netbsd-XXXXXXXX) # used to build on tmpfs
-TMPDIR=$(mktemp --tmpdir=/srv/reproducible-results -d) # accessable in schroots, used to compare results
+TMPBUILDDIR=$(mktemp --tmpdir=/srv/workspace/chroots/ -d -t rbuild-netbsd-build-XXXXXXXX) # used to build on tmpfs
+TMPDIR=$(mktemp --tmpdir=/srv/reproducible-results -d -t rbuild-netbsd-results-XXXXXXXX) # accessable in schroots, used to compare results
DATE=$(date -u +'%Y-%m-%d')
START=$(date +'%s')
trap cleanup_tmpdirs INT TERM EXIT
diff --git a/bin/reproducible_openwrt.sh b/bin/reproducible_openwrt.sh
index c5e35881..284ba44c 100755
--- a/bin/reproducible_openwrt.sh
+++ b/bin/reproducible_openwrt.sh
@@ -156,8 +156,8 @@ build_two_times() {
#
# main
#
-TMPBUILDDIR=$(mktemp --tmpdir=/srv/workspace/chroots/ -d -t openwrt-XXXXXXXX) # used to build on tmpfs
-TMPDIR=$(mktemp --tmpdir=/srv/reproducible-results -d) # accessable in schroots, used to compare results
+TMPBUILDDIR=$(mktemp --tmpdir=/srv/workspace/chroots/ -d -t rbuild-openwrt-build-XXXXXXXX) # used to build on tmpfs
+TMPDIR=$(mktemp --tmpdir=/srv/reproducible-results -d -t rbuild-openwrt-results-XXXXXXXX) # accessable in schroots, used to compare results
BANNER_HTML=$(mktemp --tmpdir=$TMPDIR)
DATE=$(date -u +'%Y-%m-%d')
START=$(date +'%s')
diff --git a/update_jdn.sh b/update_jdn.sh
index 8b859d49..f6e323a9 100755
--- a/update_jdn.sh
+++ b/update_jdn.sh
@@ -427,7 +427,7 @@ if [ "$HOSTNAME" = "jenkins" ] ; then
# samuel, lunar and josch committed with several commiters, only display one
grep -v -e "samuel.thibault@ens-lyon.org" -e Lunar -e "j.schauer@email.de" -e "mattia@mapreri.org" $TMPFILE | sudo tee -a /var/lib/jenkins/userContent/THANKS > /dev/null
rm $TMPFILE
- TMPDIR=$(mktemp -d)
+ TMPDIR=$(mktemp -d -t update-jdn-XXXXXXXX)
sudo cp -pr userContent $TMPDIR/
sudo chown -R jenkins.jenkins $TMPDIR
sudo cp -pr $TMPDIR/userContent /var/lib/jenkins/