mirror of https://github.com/docker/compose.git
Merge pull request #1525 from aanand/fix-duplicate-logging
Fix duplicate logging on up/run
This commit is contained in:
commit
e2b790f732
|
@ -336,6 +336,7 @@ class TopLevelCommand(Command):
|
||||||
container_options['ports'] = []
|
container_options['ports'] = []
|
||||||
|
|
||||||
container = service.create_container(
|
container = service.create_container(
|
||||||
|
quiet=True,
|
||||||
one_off=True,
|
one_off=True,
|
||||||
insecure_registry=insecure_registry,
|
insecure_registry=insecure_registry,
|
||||||
**container_options
|
**container_options
|
||||||
|
|
|
@ -197,6 +197,7 @@ class Service(object):
|
||||||
do_build=True,
|
do_build=True,
|
||||||
previous_container=None,
|
previous_container=None,
|
||||||
number=None,
|
number=None,
|
||||||
|
quiet=False,
|
||||||
**override_options):
|
**override_options):
|
||||||
"""
|
"""
|
||||||
Create a container for this service. If the image doesn't exist, attempt to pull
|
Create a container for this service. If the image doesn't exist, attempt to pull
|
||||||
|
@ -214,7 +215,7 @@ class Service(object):
|
||||||
previous_container=previous_container,
|
previous_container=previous_container,
|
||||||
)
|
)
|
||||||
|
|
||||||
if 'name' in container_options:
|
if 'name' in container_options and not quiet:
|
||||||
log.info("Creating %s..." % container_options['name'])
|
log.info("Creating %s..." % container_options['name'])
|
||||||
|
|
||||||
return Container.create(self.client, **container_options)
|
return Container.create(self.client, **container_options)
|
||||||
|
@ -376,6 +377,7 @@ class Service(object):
|
||||||
do_build=False,
|
do_build=False,
|
||||||
previous_container=container,
|
previous_container=container,
|
||||||
number=container.labels.get(LABEL_CONTAINER_NUMBER),
|
number=container.labels.get(LABEL_CONTAINER_NUMBER),
|
||||||
|
quiet=True,
|
||||||
)
|
)
|
||||||
self.start_container(new_container)
|
self.start_container(new_container)
|
||||||
container.remove()
|
container.remove()
|
||||||
|
|
Loading…
Reference in New Issue