From 2ec6bde3bdba0a2aabfe506f42e13e200b4280ce Mon Sep 17 00:00:00 2001 From: transcaffeine Date: Mon, 7 Oct 2024 18:18:03 +0200 Subject: [PATCH] fix(synapse): use correct key in hostvars --- roles/synapse/tasks/check.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/roles/synapse/tasks/check.yml b/roles/synapse/tasks/check.yml index 73b04bd..7f887f5 100644 --- a/roles/synapse/tasks/check.yml +++ b/roles/synapse/tasks/check.yml @@ -17,8 +17,8 @@ msg: "Required variable '{{ item }}' is undefined!" loop: "{{ synapse_required_variables }}" when: >-2 - item not in hostvars[ansible_host] - or hostvars[ansible_host][item] | length == 0 + item not in hostvars[inventory_hostname] + or hostvars[inventory_hostname][item] | length == 0 - name: Ensure conditionally required variables are given ansible.builtin.fail: