mirror of
https://github.com/docker/compose.git
synced 2025-07-09 23:04:26 +02:00
e.explanation a 'str' object
This commit is contained in:
parent
f600fa8bf3
commit
9bec059cc7
@ -67,7 +67,7 @@ class Service(object):
|
|||||||
try:
|
try:
|
||||||
return Container.create(self.client, **container_options)
|
return Container.create(self.client, **container_options)
|
||||||
except APIError as e:
|
except APIError as e:
|
||||||
if e.response.status_code == 404 and e.explanation and 'No such image' in e.explanation:
|
if e.response.status_code == 404 and e.explanation and 'No such image' in str(e.explanation):
|
||||||
log.info('Pulling image %s...' % container_options['image'])
|
log.info('Pulling image %s...' % container_options['image'])
|
||||||
self.client.pull(container_options['image'])
|
self.client.pull(container_options['image'])
|
||||||
return Container.create(self.client, **container_options)
|
return Container.create(self.client, **container_options)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user