From 58dd9d49c7532ca114ce7dba2b8d6182806a4419 Mon Sep 17 00:00:00 2001 From: James Fellows Yates Date: Wed, 15 Jun 2022 15:21:20 +0200 Subject: [PATCH] Move beforeScript exports to env scope --- conf/pipeline/eager/eva.config | 24 ++++++------------------ 1 file changed, 6 insertions(+), 18 deletions(-) diff --git a/conf/pipeline/eager/eva.config b/conf/pipeline/eager/eva.config index 55b254c..a82257a 100644 --- a/conf/pipeline/eager/eva.config +++ b/conf/pipeline/eager/eva.config @@ -6,11 +6,15 @@ params { config_profile_description = 'nf-core/eager EVA profile provided by nf-core/configs' } +env { + JAVA_TOOL_OPTIONS = "-XX:ParallelGCThreads=1" + OPENBLAS_NUM_THREADS = 1 + OMP_NUM_THREADS = 1 +} + // Specific nf-core/eager process configuration process { - beforeScript = 'export JAVA_TOOL_OPTIONS="-XX:ParallelGCThreads=1"' - maxRetries = 2 // Solution for clusterOptions comes from here: https://github.com/nextflow-io/nextflow/issues/332 + personal toMega conversion @@ -192,22 +196,10 @@ process { withName:get_software_versions { cache = false clusterOptions = { "-S /bin/bash -V -l h=!(bionode06)" } - beforeScript = 'export JAVA_TOOL_OPTIONS="-XX:ParallelGCThreads=1"; export OPENBLAS_NUM_THREADS=1; export OMP_NUM_THREADS=1' clusterOptions = { "-S /bin/bash -V -l h_vmem=${(task.memory.toMega() * 4)}M" } errorStrategy = { task.exitStatus in [1,143,137,104,134,139,140] ? 'retry' : 'finish' } } - withName:eigenstrat_snp_coverage { - beforeScript = 'export OPENBLAS_NUM_THREADS=1; export OMP_NUM_THREADS=1' - } - - withName:kraken_merge { - beforeScript = 'export OPENBLAS_NUM_THREADS=1; export OMP_NUM_THREADS=1' - } - - withName:multiqc { - beforeScript = 'export OPENBLAS_NUM_THREADS=1; export OMP_NUM_THREADS=1;' - } } profiles { @@ -226,8 +218,6 @@ profiles { process { - beforeScript = 'export JAVA_TOOL_OPTIONS="-XX:ParallelGCThreads=1"' - maxRetries = 2 // Solution for clusterOptions comes from here: https://github.com/nextflow-io/nextflow/issues/332 + personal toMega conversion @@ -404,8 +394,6 @@ profiles { process { - beforeScript = 'export JAVA_TOOL_OPTIONS="-XX:ParallelGCThreads=1"' - maxRetries = 2 // Solution for clusterOptions comes from here: https://github.com/nextflow-io/nextflow/issues/332 + personal toMega conversion