From 81e2d871aa9a9fe8fce757c5b1c139b18db361f2 Mon Sep 17 00:00:00 2001 From: Rob Parrott Date: Tue, 19 Mar 2013 13:04:57 -0400 Subject: [PATCH] inject a dictionary of avaiable variables and the environment into the executor, so that templates can be used to debug playbooks by dumping more of the available context. --- lib/ansible/runner/__init__.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/ansible/runner/__init__.py b/lib/ansible/runner/__init__.py index f0826c3bdd3..2ca710316af 100644 --- a/lib/ansible/runner/__init__.py +++ b/lib/ansible/runner/__init__.py @@ -337,6 +337,8 @@ class Runner(object): inject['hostvars'] = HostVars(self.setup_cache, self.inventory) inject['group_names'] = host_variables.get('group_names', []) inject['groups'] = self.inventory.groups_list() + inject['vars'] = self.module_vars + inject['environment'] = self.environment # allow with_foo to work in playbooks... items = None