If any Ansible task fails, there is error output, the playbook will display it newlines escaped '\n'. For tracebacks, spanning multiple lines, this make it very hard to read.
Is there a way to make ansible-playbook to display unescaped error output from shell
, pip
, git
and other similar tasks?
Add stdout_callback=debug and stderr_callback=debug in the defaults section of your ansible.cfg file.
[defaults]
(...)
stdout_callback=debug
stderr_callback=debug
This is supported by ansible > 2.0
This is fricking incredible! Why the hell isn't this the default
[default]
!?my stdout ends with
\t
. I tried this config on ansible 2.6.2. But I dont see a difference. Is there something I am missing?I got nothing from this :(
What is
stderr_callback
? It is not in sources and docs of v2.9.