A better fix for slurp, expand path in the module.

pull/191/head
Michael DeHaan 13 years ago
parent 13ba31231e
commit c6b8e1621d

@ -471,7 +471,8 @@ class Runner(object):
if self.remote_user == 'root': if self.remote_user == 'root':
metadata = '/etc/ansible/setup' metadata = '/etc/ansible/setup'
else: else:
metadata = "/home/%s/.ansible/setup" % self.remote_user # path is expanded on remote side
metadata = "~/.ansible/setup"
# install the template module # install the template module
slurp_module = self._transfer_module(conn, tmp, 'slurp') slurp_module = self._transfer_module(conn, tmp, 'slurp')

@ -42,7 +42,7 @@ params = {}
for x in items: for x in items:
(k, v) = x.split("=") (k, v) = x.split("=")
params[k] = v params[k] = v
source = params['src'] source = os.path.expanduser(params['src'])
# ========================================== # ==========================================

Loading…
Cancel
Save