Probably the best option is you could write a callback plugin that sends an email. We actually have an example of this that would run when a playbook completes:
https://github.com/ansible/ansible/blob/devel/plugins/callbacks/mail.py See the docs for info about writing callback plugins if interested, but basically you would drop this int he callback plugin path as configured in ansible.cfg. Hope that helps! you may wish to adapt the script to your particular needs. On Wed, Aug 6, 2014 at 9:56 AM, Ulrich Schreiner <[email protected] > wrote: > hi, > > we currently use ansible with a playbook to install software packages on > many servers. the installation is a vendor specific shell-script and we > need the output of this script. currently i use the "mail" action to send > the output, but with many hosts in my inventory i'm sending many mails. > > is there an option to execute a task (or something similar) after all > hosts have their tasks done? and do i have access to their registered > variables like a "task_variables" list where i can iterate over? > > thanks > </usc> > > > -- > 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/5b174229-469d-4090-b1e7-39793ba5073e%40googlegroups.com > <https://groups.google.com/d/msgid/ansible-project/5b174229-469d-4090-b1e7-39793ba5073e%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- 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/CA%2BnsWgzwiyGu490yVww2s9HoafrmCrV54en4v7wK5iHqKQPWSQ%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
