There are a few ways in which you can debug a playbook. Ansible includes both a verbose mode and a
debug module specifically for debugging. You can also use modules such as
get_url for help. These debugging techniques can also be used to examine how modules behave when you wish to learn how to use them.
debug module is really quite simple. It takes two optional arguments,
fail.msg to set the message that will be printed by the module and
fail, if set to
yes, indicates a failure to Ansible, which will cause it to stop processing the playbook for that host. We used this module earlier in the skipping modules section to bail out of a playbook if the operating system was not recognized. ...