ansible-role-nebula/tasks/determine_ip.yml

15 lines
328 B
YAML

---
- name: Get the public IP of the lighthouse
ansible.builtin.uri:
url: "https://api.ipify.org?format=json"
method: Get
register: public_ip
until: public_ip.status == 200
retries: 6
delay: 10
- name: Set the routable IP fact
ansible.builtin.set_fact:
nebula_routable_ip: "{{ public_ip.json.ip }}"
...