Ansible - Working with inventory variables
- name: 1st
tags: debug
debug: var=hostvars['{{ item }}']['ansible_eth1']['ipv4']['address']
with_items: "{{ groups['master'] }}"
- name: 2nd
tags: debug
debug: var=hostvars['{{ item }}']['ansible_default_ipv4']['address']
with_items: "{{ groups['master'] }}"