Skip to content
Snippets Groups Projects
Commit 8f0e5c45 authored by Stefano Alberto Russo's avatar Stefano Alberto Russo
Browse files

Bugfix in getting the default container runtme and in case of unsupported container runtimes.

parent f5319aba
No related branches found
No related tags found
No related merge requests found
......@@ -242,7 +242,7 @@ class SSHSingleNodeComputingManager(SingleNodeComputingManager, SSHComputingMana
else:
raise NotImplementedError('Container {} not supported'.format(task.container.type))
raise NotImplementedError('Container runtime {} not supported'.format(self.computing.default_container_runtime))
out = os_shell(run_command, capture=True)
if out.exit_code != 0:
......@@ -380,7 +380,7 @@ class SlurmSSHClusterComputingManager(ClusterComputingManager, SSHComputingManag
run_command+='docker://{}/{}:{} &> \$HOME/{}.log\\" > \$HOME/{}.sh && sbatch {} \$HOME/{}.sh"\''.format(task.container.registry, task.container.image_name, task.container.image_tag, task.uuid, task.uuid, sbatch_args, task.uuid)
else:
raise NotImplementedError('Default container runtime "{}" not supported'.format(task.computing.default_container_runtime))
raise NotImplementedError('Container runtime {} not supported'.format(task.computing.default_container_runtime))
out = os_shell(run_command, capture=True)
if out.exit_code != 0:
......
......@@ -228,7 +228,7 @@ class Computing(models.Model):
@property
def default_container_runtime(self):
return str(self.container_runtimes).split(',')[0]
return self.container_runtimes[0]
#=======================
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment