From 9000c5a8c26b18fa015cca84f4fcdfa119946560 Mon Sep 17 00:00:00 2001 From: Paul Belanger Date: Tue, 19 Mar 2019 22:10:33 -0400 Subject: [PATCH] Pass inventory file to ansible-runner It is possible for our windmill-config directory to have another inventory file. In an effort to stop ansible from picking more then one, we can force the inventory we want. Change-Id: Iaf543f0fea3a2f247205b382e86af61d1c321aa4 Signed-off-by: Paul Belanger --- launch/launch-node.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/launch/launch-node.py b/launch/launch-node.py index f1f2998..93c140b 100755 --- a/launch/launch-node.py +++ b/launch/launch-node.py @@ -100,8 +100,8 @@ def bootstrap_server(server, key, name, group, keep, timeout): SCRIPT_DIR, '..', 'playbooks', 'bootstrap-ansible') r = ansible_runner.run( - private_data_dir=runner.root, playbook='site.yaml', - project_dir=project_dir) + inventory=runner.hosts, private_data_dir=runner.root, + playbook='site.yaml', project_dir=project_dir) if r.rc: raise Exception("Ansible runner failed")