mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Work around for cwd stat problems with run_command and sudo
This fixes issue #6443
This commit is contained in:
parent
2c7d58abe0
commit
bbf320fd22
1 changed files with 2 additions and 0 deletions
|
@ -1074,6 +1074,8 @@ class AnsibleModule(object):
|
||||||
|
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
if cwd:
|
||||||
|
os.chdir(cwd)
|
||||||
cmd = subprocess.Popen(args, **kwargs)
|
cmd = subprocess.Popen(args, **kwargs)
|
||||||
|
|
||||||
if data:
|
if data:
|
||||||
|
|
Loading…
Reference in a new issue