Domain Join Issues - UCS5.0-8 - Automation via. Ansible

Hi,

look here. The linked script should give you an idea on what to do or embed it in your playbook.