In this video we use Ansible to send a bash script to the target server and then after verifying the drive we wish to format, execute the commands from an Ansible task that format the drive and mount it to the directory we wish.
Naturally formatting a drive is destructive and the script we are providing comes with no warranty expressed or implied. We use it for our purposes and it works for us. If you format a drive you did not intend to with this script, you've been warned.
Here is a link to the Ansible script and the Bash script it uses:
https://cloud.compumatter.biz/s/rBkWW...