You have several options, depending on the scope:

- mail task (trigger when: yum_update is failed/ task in rescue/always
part of a block, disk_usage > 75, etc)
https://docs.ansible.com/ansible/5/collections/community/general/mail_module.html
- mail callback (handles any failures in run)
https://docs.ansible.com/ansible/latest/collections/community/general/mail_callback.html#ansible-collections-community-general-mail-callback

-- 
----------
Brian Coca

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CACVha7d%3DTvi9k2XcFTRx6hgg%2BpqwPx-rLH_08EAxOyZqJTYKRA%40mail.gmail.com.

Reply via email to