---
- name: Prune docker
hosts: all
vars:
prune_def: "Total reclaimed space: 0B"
tasks:
- name: Docker prune all
command: docker system prune -af
register: docker_prune
changed_when: docker_prune.stdout != prune_def