File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -688,12 +688,12 @@ def get_env(self):
688688class SlurmSpawner (UserEnvMixin , BatchSpawnerRegexStates ):
689689 batch_script = Unicode (
690690 """#!/bin/bash
691- #SBATCH --output={{homedir}}/jupyterhub_slurmspawner_%j.log
692691#SBATCH --job-name=spawner-jupyterhub
693692#SBATCH --chdir={{homedir}}
694693#SBATCH --export={{keepvars}}
695694#SBATCH --get-user-env=L
696- {% if partition %}#SBATCH --partition={{partition}}
695+ {% if output %}#SBATCH --output={% if not output.startswith('/') %}{{homedir}}/{% endif %}{{output}}
696+ {% endif %}{% if partition %}#SBATCH --partition={{partition}}
697697{% endif %}{% if runtime %}#SBATCH --time={{runtime}}
698698{% endif %}{% if memory %}#SBATCH --mem={{memory}}
699699{% endif %}{% if gres %}#SBATCH --gres={{gres}}
@@ -740,6 +740,12 @@ class SlurmSpawner(UserEnvMixin, BatchSpawnerRegexStates):
740740 help = "Additional resources (e.g. GPUs) requested" ,
741741 ).tag (config = True )
742742
743+ req_output = Unicode (
744+ "jupyterhub_slurmspawner_%j.log" ,
745+ help = "Batch script standard output and standard error filename pattern."
746+ "Relative filename is considered relative to ``req_homedir``." ,
747+ ).tag (config = True )
748+
743749 # outputs line like "Submitted batch job 209"
744750 batch_submit_cmd = Unicode ("sbatch --parsable" ).tag (config = True )
745751 # outputs status and exec node like "RUNNING hostname"
You can’t perform that action at this time.
0 commit comments