Merge pull request #5723 from jeromew/ssh_chmod_bug

Bug: chmod should be called only if the tmp dir was created in the first...
pull/5724/head
jctanner 11 years ago
commit 293d9b490e

@ -328,7 +328,7 @@ class Runner(object):
environment_string = self._compute_environment_string(inject)
if (self.sudo or self.su) and (self.sudo_user != 'root' or self.su_user != 'root'):
if tmp.find("tmp") != -1 and (self.sudo or self.su) and (self.sudo_user != 'root' or self.su_user != 'root'):
# deal with possible umask issues once sudo'ed to other user
cmd_chmod = "chmod a+r %s" % remote_module_path
self._low_level_exec_command(conn, cmd_chmod, tmp, sudoable=False)

Loading…
Cancel
Save