On Thu, 22 Aug 2019 12:26:00 -0700 (PDT) Mohtashim S <[email protected]> wrote:
> - name: "Play 1"
> [...]
> - add_host: name={{ item }}
> groups=dest_nodes
> ansible_user={{ USER }}
> with_items: "{{ Dest_IP.split(',') }}"
> [...]
> - name: "Play 3"
> [...]
> vars:
> dbfiledet: "{{ hostvars['dest_nodes']['f_APP'] }}"
"dest_nodes" is the group of hosts. "hostvars" requires a host as an index.
This is the reason of the error:
The error was: "hostvars['dest_nodes']" is undefined
Cheers,
-vlado
--
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/20190822233519.260d4a84%40gmail.com.
pgpl957G5cgVv.pgp
Description: OpenPGP digital signature
