diff options
author | Daniel Hokka Zakrisson <daniel@hozac.com> | 2012-11-16 23:42:40 +0100 |
---|---|---|
committer | Daniel Hokka Zakrisson <daniel@hozac.com> | 2012-11-16 23:46:17 +0100 |
commit | 021172f78dc3fe07356c24d565ae2e0ec81ae30c (patch) | |
tree | b119f0ceef26f7f3a7c44eed1ac84c6c2c803019 /lib/ansible/runner | |
parent | 0ab3bd003485f5b1711341b016d401f662644246 (diff) | |
download | ansible-021172f78dc3fe07356c24d565ae2e0ec81ae30c.tar.gz |
Use the configured remote_tmp even for root
Diffstat (limited to 'lib/ansible/runner')
-rw-r--r-- | lib/ansible/runner/__init__.py | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/ansible/runner/__init__.py b/lib/ansible/runner/__init__.py index b41d28248d..93924d402c 100644 --- a/lib/ansible/runner/__init__.py +++ b/lib/ansible/runner/__init__.py @@ -491,9 +491,7 @@ class Runner(object): basefile = 'ansible-%s-%s' % (time.time(), random.randint(0, 2**48)) basetmp = os.path.join(C.DEFAULT_REMOTE_TMP, basefile) - if self.remote_user == 'root': - basetmp = os.path.join('/var/tmp', basefile) - elif self.sudo and self.sudo_user != 'root': + if self.sudo and self.sudo_user != 'root': basetmp = os.path.join('/tmp', basefile) cmd = 'mkdir -p %s' % basetmp |