From aa8b35d893d2746164523ef390cc51685854550f Mon Sep 17 00:00:00 2001 From: bpinsard Date: Wed, 9 Aug 2023 11:07:04 -0400 Subject: [PATCH 1/2] add matplotlib envvar, fix non-writeable cache dir error --- scripts/singularity_cmd | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/singularity_cmd b/scripts/singularity_cmd index ce4597f3..5d900e50 100755 --- a/scripts/singularity_cmd +++ b/scripts/singularity_cmd @@ -78,6 +78,10 @@ if [ -n "${DATALAD_CONTAINER_NAME:-}" ]; then export APPTAINERENV_DATALAD_CONTAINER_NAME="$DATALAD_CONTAINER_NAME" fi +# fix non-writable matplotlib cache dir in apptainer https://github.com/ReproNim/containers/issues/97 +export SINGULARITYENV_MPLCONFIGDIR=/tmp +export APPTAINERENV_MPLCONFIGDIR=/tmp + # singularity bind mounts system /tmp, which might result in side-effects # Create a dedicated temporary directory to be removed upon completion # Mac's tmpdir (with default options) causes problems when a singularity From 9f824dc8bc7503478ac23dc7025ceb5d514d2c70 Mon Sep 17 00:00:00 2001 From: Basile Date: Wed, 9 Aug 2023 16:37:10 -0400 Subject: [PATCH 2/2] Update scripts/singularity_cmd Co-authored-by: Yaroslav Halchenko --- scripts/singularity_cmd | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/singularity_cmd b/scripts/singularity_cmd index 5d900e50..90f0ebd7 100755 --- a/scripts/singularity_cmd +++ b/scripts/singularity_cmd @@ -79,8 +79,8 @@ if [ -n "${DATALAD_CONTAINER_NAME:-}" ]; then fi # fix non-writable matplotlib cache dir in apptainer https://github.com/ReproNim/containers/issues/97 -export SINGULARITYENV_MPLCONFIGDIR=/tmp -export APPTAINERENV_MPLCONFIGDIR=/tmp +export SINGULARITYENV_MPLCONFIGDIR=/tmp/mpl-config +export APPTAINERENV_MPLCONFIGDIR=/tmp/mpl-config # singularity bind mounts system /tmp, which might result in side-effects # Create a dedicated temporary directory to be removed upon completion