Moving this to ansible-devel.
On Fri, Dec 5, 2014 at 11:16 AM, Romey-Rome <[email protected]> wrote: > I'm executing a playbook from a Flask web service. All output goes to > stdout console. I need it in my webapp so that I can send it back to the > browser. Best I can get on the server is the summary stats counter from the > pb object. (success,skipped,failed,etc) > > How can I get the complete output like with ansible.Runner()? > > stats = callbacks.AggregateStats() > playbook_cb = callbacks.PlaybookCallbacks(verbose=utils.VERBOSITY) > runner_cb = > callbacks.PlaybookRunnerCallbacks(stats,verbose=utils.VERBOSITY) > > pb = ansible.playbook.PlayBook( > playbook = playbook > stats=stats, > inventory=targets, > callbacks=playbook_cb, > runner_callbacks=runner_cb > ).run() > > Thanks! > > -- > You received this message because you are subscribed to the Google Groups > "Ansible Project" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/ansible-project/2eae5651-aa35-4f9a-9ada-5dd96106753f%40googlegroups.com > <https://groups.google.com/d/msgid/ansible-project/2eae5651-aa35-4f9a-9ada-5dd96106753f%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- Matt Martz @sivel sivel.net -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/CAD8N0v-mmXJSEv8vNoy0VT1z3Ocw1PbaEEZPgKFrQQH9JC1hww%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
