diff --git a/journal_upload/tasks/main.yml b/journal_upload/tasks/main.yml index 54fceff..89604c5 100644 --- a/journal_upload/tasks/main.yml +++ b/journal_upload/tasks/main.yml @@ -16,12 +16,14 @@ install_recommends: false state: present +# A node reaching its own address arrives at Traefik from its cilium_host address, which the +# NetBird allowlist rejects; it takes the other nodes. - name: Pin the ingest name to the NetBird addresses ansible.builtin.blockinfile: path: /etc/hosts marker: "# {mark} journal_upload" block: | - {% for address in journal_upload.addresses %} + {% for address in journal_upload.addresses | reject('in', ansible_facts.all_ipv4_addresses) %} {{ address }} {{ journal_upload.host }} {% endfor %} notify: Restart systemd-journal-upload