summaryrefslogtreecommitdiff
path: root/compose/cli
diff options
context:
space:
mode:
authorJoffrey F <joffrey@docker.com>2016-05-16 14:59:33 -0700
committerJoffrey F <joffrey@docker.com>2016-05-16 14:59:33 -0700
commit844b7d463f63b4bd3915648b32432c9b3d0243c8 (patch)
tree87cbaa9558777c25efc5b033f7b912014ecd94f9 /compose/cli
parentca3aef0c84a91c2cc6996ebb833f566c9243fa98 (diff)
Update rm command to always remove one-off containers.
Signed-off-by: Joffrey F <joffrey@docker.com>
Diffstat (limited to 'compose/cli')
-rw-r--r--compose/cli/main.py12
1 files changed, 5 insertions, 7 deletions
diff --git a/compose/cli/main.py b/compose/cli/main.py
index 3ab2f965..afde7150 100644
--- a/compose/cli/main.py
+++ b/compose/cli/main.py
@@ -532,17 +532,15 @@ class TopLevelCommand(object):
Options:
-f, --force Don't ask to confirm removal
-v Remove any anonymous volumes attached to containers
- -a, --all Also remove one-off containers created by
+ -a, --all Obsolete. Also remove one-off containers created by
docker-compose run
"""
if options.get('--all'):
- one_off = OneOffFilter.include
- else:
log.warn(
- 'Not including one-off containers created by `docker-compose run`.\n'
- 'To include them, use `docker-compose rm --all`.\n'
- 'This will be the default behavior in the next version of Compose.\n')
- one_off = OneOffFilter.exclude
+ '--all flag is obsolete. This is now the default behavior '
+ 'of `docker-compose rm`'
+ )
+ one_off = OneOffFilter.include
all_containers = self.project.containers(
service_names=options['SERVICE'], stopped=True, one_off=one_off