Brian / Todd .. good eyes!

Walter
--
Walter Rowe, Division Chief
Infrastructure Services, OISM
Mobile: 202.355.4123

On Sep 21, 2023, at 10:22 AM, Brian Coca <[email protected]> wrote:

You are confusing scopes, `set_fact` is PER HOST, not a global. So you
defined the variable on server1 but are trying to read it from
127.0.0.1.

So to access in the 2nd play you need to go through hostvars:
{{hostvasr['server1']['reg_name']
--
----------
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://gcc02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgroups.google.com%2Fd%2Fmsgid%2Fansible-project%2FCACVha7f1zJc8ni3tG415F2EWiQDHZDyTVNnTZsvSvzgCzmgbSw%2540mail.gmail.com&data=05%7C01%7Cwalter.rowe%40nist.gov%7C8af8d8d876cf4490a1b808dbbaae4ad3%7C2ab5d82fd8fa4797a93e054655c61dec%7C1%7C0%7C638309029959489682%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=j7qzTtXfQ1g3uGSzohc4lw6cWSlGY3ySy6c67uEuia0%3D&reserved=0.

-- 
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/1E11EF33-1F49-47AD-9DEF-14F156638169%40nist.gov.

Reply via email to