mirror of
https://gitlab.ub.uni-bielefeld.de/sfb1288inf/nopaque.git
synced 2024-12-24 02:24:20 +00:00
Comment --keep_intermediates
This commit is contained in:
parent
1092312e6d
commit
a3039e0529
@ -23,9 +23,8 @@ class Swarm:
|
||||
_command = job['service'] \
|
||||
+ ' -i /files/{}'.format(job['id']) \
|
||||
+ ' -l {}'.format(job['service_args']['lang']) \
|
||||
+ ' -o /files/{}/output'.format(job['id']) \
|
||||
+ ' --keep-intermediates' \
|
||||
+ ' --nCores {}'.format(job['requested_cpus'])
|
||||
+ ' -o /files/{}/output'.format(job['id'])
|
||||
# + ' --keep-intermediates'
|
||||
_constraints = ['node.role==worker']
|
||||
_image = 'gitlab.ub.uni-bielefeld.de:4567/sfb1288inf/{}:{}'.format(
|
||||
job['service'],
|
||||
@ -63,6 +62,8 @@ class Swarm:
|
||||
' (name=_name). Because there is no id generator for now, it is
|
||||
' not set, so that the Docker engine assigns a random name.
|
||||
'''
|
||||
print(_command)
|
||||
print(_image)
|
||||
service = self.docker.services.create(
|
||||
_image,
|
||||
command=_command,
|
||||
@ -80,6 +81,7 @@ class Swarm:
|
||||
' method) the poll loop also checks if the task list is empy (The
|
||||
' not service.tasks() condition implements this).
|
||||
'''
|
||||
print(service.attrs)
|
||||
while not service.tasks() or \
|
||||
service.tasks()[0].get('Status').get('State') != 'complete':
|
||||
time.sleep(1)
|
||||
|
Loading…
Reference in New Issue
Block a user