Can you try the *block/catch *and see if that works?

https://docs.ansible.com/ansible/latest/user_guide/playbooks_blocks.html

ansible_failed_taskThe task that returned ‘failed’ and triggered the
rescue. For example, to get the name use ansible_failed_task.name.
ansible_failed_resultThe captured return result of the failed task that
triggered the rescue. This would equate to having used this var in the
register keyword.

*Regards,*
*Ankit*


On Fri, Mar 8, 2019 at 4:50 PM Michał Misiak <[email protected]>
wrote:

> Yes, I know. And I catch gather facts from connected machine and save them
> in .csv file. This file is my informaction about hosts which ansbile can
> connection only, but I would like to have information about all of host.
> What can I catch a fatal messege about connection refused to some host and
> transfer them to file?
>
> --
> 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/f1c98059-bdec-40a1-890b-28bfc09635cd%40googlegroups.com
> <https://groups.google.com/d/msgid/ansible-project/f1c98059-bdec-40a1-890b-28bfc09635cd%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/CACecUhteLWXe7FW5bvr3qQzC0hriR-vUcqjFh2K-VaXZcjnspg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to