mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Fixes #6567 put the git wrapper script in the module temp dir
This commit is contained in:
parent
324a943e12
commit
67517e96d3
2 changed files with 4 additions and 1 deletions
|
@ -1142,3 +1142,5 @@ class AnsibleModule(object):
|
|||
break
|
||||
return '%.2f %s' % (float(size)/ limit, suffix)
|
||||
|
||||
def get_module_path():
|
||||
return os.path.dirname(os.path.realpath(__file__))
|
||||
|
|
|
@ -143,7 +143,8 @@ import re
|
|||
import tempfile
|
||||
|
||||
def write_ssh_wrapper():
|
||||
fd, wrapper_path = tempfile.mkstemp()
|
||||
module_dir = get_module_path()
|
||||
fd, wrapper_path = tempfile.mkstemp(prefix=module_dir + '/')
|
||||
fh = os.fdopen(fd, 'w+b')
|
||||
template = """#!/bin/sh
|
||||
if [ -z "$GIT_SSH_OPTS" ]; then
|
||||
|
|
Loading…
Reference in a new issue