aboutsummaryrefslogtreecommitdiff
path: root/tests/stress_tests/parallel_cp.sh
diff options
context:
space:
mode:
Diffstat (limited to 'tests/stress_tests/parallel_cp.sh')
-rwxr-xr-xtests/stress_tests/parallel_cp.sh7
1 files changed, 6 insertions, 1 deletions
diff --git a/tests/stress_tests/parallel_cp.sh b/tests/stress_tests/parallel_cp.sh
index b9e6b4b..ad98e5e 100755
--- a/tests/stress_tests/parallel_cp.sh
+++ b/tests/stress_tests/parallel_cp.sh
@@ -12,6 +12,11 @@
#
# See https://github.com/rfjakob/gocryptfs/issues/322 for details.
+if [[ -z $TMPDIR ]]; then
+ TMPDIR=/var/tmp
+ export TMPDIR
+fi
+
cd "$(dirname "$0")"
MYNAME=$(basename $0)
source ../fuse-unmount.bash
@@ -20,7 +25,7 @@ source ../fuse-unmount.bash
GOPATH=$(go env GOPATH)
# Backing directory
-DIR=$(mktemp -d /tmp/$MYNAME.XXX)
+DIR=$(mktemp -d $TMPDIR/$MYNAME.XXX)
$GOPATH/bin/gocryptfs -q -init -extpass "echo test" -scryptn=10 $DIR
# Mountpoint