From e599f5aabe40427550ed1ab935280ae5b6e491ec Mon Sep 17 00:00:00 2001 From: Nicolas Singh Oteiza Date: Mon, 25 Feb 2019 05:15:15 -0300 Subject: [PATCH] Add docker_prune sample to remove everything, including non-dangling images (#52744) * Update docker_prune.py ##### SUMMARY Add example to remove everything, including non-dangling images ##### ISSUE TYPE - Docs Pull Request +label: docsite_pr * fix indentation * Update lib/ansible/modules/cloud/docker/docker_prune.py Co-Authored-By: nicosingh --- lib/ansible/modules/cloud/docker/docker_prune.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/lib/ansible/modules/cloud/docker/docker_prune.py b/lib/ansible/modules/cloud/docker/docker_prune.py index cef54ce6aa..6ed20f0069 100644 --- a/lib/ansible/modules/cloud/docker/docker_prune.py +++ b/lib/ansible/modules/cloud/docker/docker_prune.py @@ -105,6 +105,16 @@ EXAMPLES = ''' networks: yes volumes: yes builder_cache: yes + +- name: Prune everything (including non-dangling images) + docker_prune: + containers: yes + images: yes + images_filters: + dangling: false + networks: yes + volumes: yes + builder_cache: yes ''' RETURN = '''