From 214b0b052c3d54b58a531b0f7fb401ec3c0229f5 Mon Sep 17 00:00:00 2001 From: James Tanner Date: Tue, 22 Oct 2013 12:00:54 -0400 Subject: [PATCH] Fixes #4608 add lookup to template globals to make plugins work again --- lib/ansible/utils/template.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/ansible/utils/template.py b/lib/ansible/utils/template.py index fb777a4636..5fdd6ab614 100644 --- a/lib/ansible/utils/template.py +++ b/lib/ansible/utils/template.py @@ -504,6 +504,8 @@ def template_from_string(basedir, data, vars, fail_on_undefined=False): else: return data + t.globals['lookup'] = my_lookup + try: return t.render(vars) except jinja2.exceptions.UndefinedError: