introduce exception in inventory with all option

15 views
Skip to first unread message

Marcos González

unread,
Jul 10, 2019, 12:17:45 PM7/10/19
to ansible...@googlegroups.com
Hi all

Im checking to use dynamic inventory but Im having a problem when execute any tasks with all option because with dynamic inventory exists some servers that never connects for external reasons. Exist any form to introduce exceptions in hosts?

Exemple:
---
-hosts: all

A would like to discard test servers in tag_name. Is it possible?

Thanks
--

Marcos González

unread,
Jul 10, 2019, 12:32:49 PM7/10/19
to ansible...@googlegroups.com

Brian Coca

unread,
Jul 15, 2019, 4:06:01 PM7/15/19
to Ansible Project
it is 'host patterns', you can also

- hosts: all:!notthese

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


--
----------
Brian Coca
Reply all
Reply to author
Forward
0 new messages