diff --git a/deployment/podman/podman-baremetal-ansible.yaml b/deployment/podman/podman-baremetal-ansible.yaml index 63f8f6c408..c9cf9cedff 100644 --- a/deployment/podman/podman-baremetal-ansible.yaml +++ b/deployment/podman/podman-baremetal-ansible.yaml @@ -117,6 +117,16 @@ outputs: package: name: docker state: absent + - name: Get the list of directory mounted under /var/lib/docker/ orderer. + shell: | + mount | awk '/\/var\/lib\/docker\/[^/]+\// {print $3}'; + mount | awk '/\/var\/lib\/docker\/[^/]+$/ {print $3}'; + register: unmounted_dirs + - name: Unmount those directories + mount: + path: "{{ item }}" + state: unmounted + loop: "{{ unmounted_dirs.stdout_lines }}" - name: Purge /var/lib/docker file: path: /var/lib/docker