From 10a30d68d50a8a3a7d70bcd21fbfc0acdf06211f Mon Sep 17 00:00:00 2001 From: Chris Hammer Date: Wed, 21 Sep 2022 22:29:18 -0400 Subject: [PATCH] update conditional --- roles/create_ansible_inventory/templates/ansible_inventory.j2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/roles/create_ansible_inventory/templates/ansible_inventory.j2 b/roles/create_ansible_inventory/templates/ansible_inventory.j2 index 8f7a38b..570f9d5 100644 --- a/roles/create_ansible_inventory/templates/ansible_inventory.j2 +++ b/roles/create_ansible_inventory/templates/ansible_inventory.j2 @@ -55,6 +55,6 @@ # vars for all hosts/groups [all:vars] -{% if __use_bastion is defined and __use_bastion|bool %} +{% if __bastion_user is defined and __bastion_host is defined %} ansible_ssh_common_args='-J {{ __bastion_user }}@{{ __bastion_host }}' {% endif %}