Remove stderr/stdout from json output on failure as plugin handles already pretty printing

13 views
Skip to first unread message

Kamil Demecki

unread,
Jul 11, 2016, 8:59:05 AM7/11/16
to Ansible Project
Hi All,

I'm using plugin described here to display pretty printed output. It is working very well on successful execution.
However on failure ansible also displays json with keys "stdout", "stderr" duplicating my output.
Json is quite big and unreadable as I log hundreds lines in some places.

Is there a way to "mask" keys from json output presented when ansible fails? I would like to have a dict with something like replaced stderr="Already printed".
I've tried to modify dictionary in callback plugin but it doesn't take effect. Is any good example on github?

I'm using Ansible 2.0.0.1.

Thanks
Reply all
Reply to author
Forward
0 new messages