diff --git a/source/resources/playbooks/roles/ParallelClusterHeadNode/templates/opt/slurm/modules/modulefiles/slurm/.template b/source/resources/playbooks/roles/ParallelClusterHeadNode/templates/opt/slurm/modules/modulefiles/slurm/.template index 24490499..be83033b 100644 --- a/source/resources/playbooks/roles/ParallelClusterHeadNode/templates/opt/slurm/modules/modulefiles/slurm/.template +++ b/source/resources/playbooks/roles/ParallelClusterHeadNode/templates/opt/slurm/modules/modulefiles/slurm/.template @@ -31,80 +31,6 @@ setenv SLURM_CONF {{SubmitterSlurmBaseDir}}/etc/slurm.conf setenv SLURM_CLUSTER_NAME {{ClusterName}} -# sbatch defaults -if { [ module-info mode load ] || [ module-info mode display ] } { - if { ! [ info exists ::env(SBATCH_MEM_PER_NODE) ] } { - setenv SBATCH_MEM_PER_NODE 100M - setenv SBATCH_MEM_PER_NODE_SET "" - } - if { ! ( [ info exists ::env(SBATCH_REQUEUE) ] || [ info exists ::env(SBATCH_NO_REQUEUE) ] ) } { - setenv SBATCH_REQUEUE "" - setenv SBATCH_REQUEUE_SET "" - } - if { ! [ info exists ::env(SBATCH_TIMELIMIT) ] } { - setenv SBATCH_TIMELIMIT "1:0:0" - setenv SBATCH_TIMELIMIT_SET "" - } - if { ! [ info exists ::env(SBATCH_PARTITION) ] } { - setenv SBATCH_PARTITION "{{DefaultPartition}}" - setenv SBATCH_PARTITION_SET "" - } -} elseif { [ module-info mode remove ] } { - if { [ info exists ::env(SBATCH_MEM_PER_NODE_SET) ] } { - unsetenv SBATCH_MEM_PER_NODE - unsetenv SBATCH_MEM_PER_NODE_SET - } - if { [ info exists ::env(SBATCH_REQUEUE_SET) ] } { - unsetenv SBATCH_REQUEUE - unsetenv SBATCH_REQUEUE_SET - } - if { [ info exists ::env(SBATCH_TIMELIMIT_SET) ] } { - unsetenv SBATCH_TIMELIMIT - unsetenv SBATCH_TIMELIMIT_SET - } - if { [ info exists ::env(SBATCH_PARTITION_SET) ] } { - unsetenv SBATCH_PARTITION - unsetenv SBATCH_PARTITION_SET - } -} - -# srun defaults -if { [ module-info mode load ] || [ module-info mode display ] } { - if { ! [ info exists ::env(SLURM_CPUS_PER_TASK) ] } { - setenv SLURM_CPUS_PER_TASK 1 - setenv SLURM_CPUS_PER_TASK_SET "" - } - if { ! [ info exists ::env(SLURM_MEM_PER_NODE) ] } { - setenv SLURM_MEM_PER_NODE 100M - setenv SLURM_MEM_PER_NODE_SET "" - } - if { ! [ info exists ::env(SLURM_PARTITION) ] } { - setenv SLURM_PARTITION "{{DefaultPartition}}" - setenv SLURM_PARTITION_SET "" - } - if { ! [ info exists ::env(SLURM_TIMELIMIT) ] } { - setenv SLURM_TIMELIMIT "1:0:0" - setenv SLURM_TIMELIMIT_SET "" - } -} elseif { [ module-info mode remove ] } { - if { [ info exists ::env(SLURM_CPUS_PER_TASK_SET) ] } { - unsetenv SLURM_CPUS_PER_TASK - unsetenv SLURM_CPUS_PER_TASK_SET - } - if { [ info exists ::env(SLURM_MEM_PER_NODE_SET) ] } { - unsetenv SLURM_MEM_PER_NODE - unsetenv SLURM_MEM_PER_NODE_SET - } - if { ! [ info exists ::env(SLURM_PARTITION_SET) ] } { - unsetenv SLURM_PARTITION - unsetenv SLURM_PARTITION_SET - } - if { [ info exists ::env(SLURM_TIMELIMIT_SET) ] } { - unsetenv SLURM_TIMELIMIT - unsetenv SLURM_TIMELIMIT_SET - } -} - # squeue defaults # # Output format