1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Allow the remote MD5 checks to be run via sudo

This commit is contained in:
Ben Ritcey 2013-05-15 18:14:31 -04:00 committed by Michael DeHaan
parent 8475a92dec
commit 0938d4d89a

View file

@ -638,7 +638,7 @@ class Runner(object):
cmd = " || ".join(md5s) cmd = " || ".join(md5s)
cmd = "%s; %s || (echo \"${rc} %s\")" % (test, cmd, path) cmd = "%s; %s || (echo \"${rc} %s\")" % (test, cmd, path)
data = self._low_level_exec_command(conn, cmd, tmp, sudoable=False) data = self._low_level_exec_command(conn, cmd, tmp, sudoable=True)
data2 = utils.last_non_blank_line(data['stdout']) data2 = utils.last_non_blank_line(data['stdout'])
try: try:
return data2.split()[0] return data2.split()[0]