How to see stdout of ansible commands?
For example, in a bash script that calls ansible: set -m touch /tmp/debug.log && tail -f /tmp/debug.log & ansible-playbook ... call playbook here kill %1 # ensure the background tail job is stopped Then in some ansible role:
Where we can see the stdout or stdout_lines section for the standard output of the command execution. Also, as we have used the verbose mode while running the ansible-playbook command, we can see other return values as well like command execution start, delta, end time and rc, etc.