diff --git a/lib/ansible/utils.py b/lib/ansible/utils.py index 29b164de910..aacc9d5d6d1 100644 --- a/lib/ansible/utils.py +++ b/lib/ansible/utils.py @@ -257,8 +257,8 @@ def varReplace(raw, vars): def template(text, vars, setup_cache, no_engine=True): ''' run a text buffer through the templating engine ''' vars = vars.copy() - text = varReplace(unicode(text), vars) vars['hostvars'] = setup_cache + text = varReplace(unicode(text), vars) if no_engine: # used when processing include: directives so that Jinja is evaluated # in a later context when more variables are available