cleanserver.yml
371 Bytes
---
- hosts: FormatAppDisk
become: true
tasks:
# Read device information (always use unit when probing)
- parted: device={{ app_disk }} unit=MiB
register: sdb_info
# Remove all partitions from disk
- parted:
device: {{ app_disk }}
number: "{{ item.num }}"
state: absent
with_items:
- "{{ sdb_info.partitions }}"