--- - hosts: all gather_facts: false tasks: - name: Remove deploy.d folder file: path: "{{ app_config_root }}" state: absent - name: Remove database(s) shell: "dokku {{ item.type }}:destroy {{ app }} --force" args: removes: "/var/lib/dokku/services/{{ item.type }}/{{ app }}" with_items: "{{ db }}"