From ce176b022a83df5e20c86d435adf98559de84ee2 Mon Sep 17 00:00:00 2001 From: Igor Konnov Date: Fri, 13 Dec 2024 17:48:58 +0100 Subject: [PATCH] handle TMPDIR for docker --- src/universal/bin/apalache-mc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/universal/bin/apalache-mc b/src/universal/bin/apalache-mc index 5689e8028f..d75083b0cf 100755 --- a/src/universal/bin/apalache-mc +++ b/src/universal/bin/apalache-mc @@ -39,7 +39,11 @@ then fi # Avoid SANY concurrency issues: https://github.com/tlaplus/tlaplus/issues/688 -TD=`mktemp -d "$TMPDIR"/SANYXXXXXXXXXX` +if [ -z "$TMPDIR" ]; then + TMPDIR="$(pwd)/tmp" + mkdir -p "$TMPDIR" +fi +TD=`mktemp -d -p $TMPDIR -t SANYXXXXXXXXXX` JVM_ARGS="${JVM_ARGS} -Djava.io.tmpdir=$TD" # Check whether the CLI args contains the debug flag