--- | |
- name: Normalized name for public address | |
cache: | |
key: 'public_address' | |
value: '{{ inventory_hostname }}' | |
- block: | |
- name: Update cache for public ip on AWS | |
ec2_facts: | |
when: ansible_ec2_public_ipv4 is not defined | |
- name: Normalized name for public address on AWS | |
cache: | |
key: 'public_address' | |
value: '{{ ansible_ec2_public_ipv4 | default(inventory_hostname) }}' | |
when: ansible_bios_version is defined and ansible_bios_version | search('amazon') |