Merge pull request #2623 from willthames/when_set_bug

Prevent premature variable substitution in tasks
This commit is contained in:
Michael DeHaan 2013-04-12 17:19:25 -07:00
commit e7f5186dec
3 changed files with 60 additions and 1 deletions

View file

@ -65,7 +65,11 @@ class Play(object):
self._update_vars_files_for_host(None)
self._ds = ds = template.template(basedir, ds, self.vars)
for key in ds:
if key != 'tasks':
ds[key] = template.template(basedir, ds[key], self.vars)
self._ds = ds
hosts = ds.get('hosts')
if hosts is None: