From e31dd8e318bc6bc889b471a57e4559376591a9e5 Mon Sep 17 00:00:00 2001 From: Luke Meyer Date: Fri, 10 Nov 2017 14:51:52 -0500 Subject: ansible.cfg: error when inventory does not parse As of Ansible 2.4 this option exists: https://github.com/ansible/ansible/issues/15035#issuecomment-329672168 The kind of error you get later when this is your real problem tends to be *very* confusing. Much better to just fail right away. --- ansible.cfg | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'ansible.cfg') diff --git a/ansible.cfg b/ansible.cfg index 589a58e9d..5a4c1cd80 100644 --- a/ansible.cfg +++ b/ansible.cfg @@ -33,6 +33,10 @@ callback_whitelist = profile_tasks # Uncomment to use the provided AWS dynamic inventory script #hostfile = inventory/aws/ec2.py +[inventory] +# fail more helpfully when the inventory file does not parse (Ansible 2.4+) +unparsed_is_failed=true + # Additional ssh options for OpenShift Ansible [ssh_connection] pipelining = True -- cgit v1.2.3