<div dir="ltr"><div><div>Thanks Monty for pointing that out to me today on #ansible-devel.</div><div><br></div><div>Context: <a href="https://github.com/ansible/ansible/pull/41811">https://github.com/ansible/ansible/pull/41811</a></div><div>The top-level fact vars are currently being deprecated in Ansible, maybe 2.7.</div><div>It looks like it only affects tripleo-validations (in a quick look), but it could be more.</div><div>See: <a href="http://codesearch.openstack.org/?q=ansible_facts&i=nope&files=&repos=">http://codesearch.openstack.org/?q=ansible_facts&i=nope&files=&repos=</a></div></div><div><br></div><div>An example playbook was written to explain what is deprecated:</div><div><a href="https://github.com/ansible/ansible/pull/41811#issuecomment-399220997">https://github.com/ansible/ansible/pull/41811#issuecomment-399220997</a><br></div><div><br></div><div>But it seems like, starting with Ansible 2.5 (what we already have in Rocky and beyond), we should encourage the usage of ansible_facts dictionary.</div><div>Example:</div><div>var=hostvars[inventory_hostname].ansible_facts.hostname<br></div><div>instead of:</div><div>var=ansible_hostname<br></div><div><br></div><div>Can we have someone from TripleO Validations to help, and make sure we make it working for future versions of Ansible.</div><div>Also there is a way to test this behavior by disabling the 'inject_facts_as_vars' option in ansible.cfg.</div><div><br></div><div>Hope this helps,</div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr">Emilien Macchi<br></div></div></div>