File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -516,6 +516,11 @@ class SlurmSpawner(UserEnvMixin,BatchSpawnerRegexStates):
516
516
help = "QoS name to submit job to resource manager"
517
517
).tag (config = True )
518
518
519
+ req_srun = Unicode ('srun' ,
520
+ help = "Job step wrapper, default 'srun'. Set to '' you do not want "
521
+ "to run in job step (affects environment handling)"
522
+ ).tag (config = True )
523
+
519
524
batch_script = Unicode ("""#!/bin/bash
520
525
#SBATCH --output={{homedir}}/jupyterhub_slurmspawner_%j.log
521
526
#SBATCH --job-name=spawner-jupyterhub
@@ -531,7 +536,7 @@ class SlurmSpawner(UserEnvMixin,BatchSpawnerRegexStates):
531
536
trap 'echo SIGTERM received' TERM
532
537
{{prologue}}
533
538
which jupyterhub-singleuser
534
- srun {{cmd}}
539
+ {% if srun %}{{srun}} {% endif %} {{cmd}}
535
540
echo "jupyterhub-singleuser ended gracefully"
536
541
{{epilogue}}
537
542
""" ).tag (config = True )
You can’t perform that action at this time.
0 commit comments