mirror of
https://github.com/ansible/awx.git
synced 2026-02-18 11:40:05 -03:30
Allow proot's base tmp path to be configurable
This commit is contained in:
@@ -446,7 +446,8 @@ def build_proot_temp_dir():
|
||||
'''
|
||||
Create a temporary directory for proot to use.
|
||||
'''
|
||||
path = tempfile.mkdtemp(prefix='ansible_tower_proot_')
|
||||
from django.conf import settings
|
||||
path = tempfile.mkdtemp(prefix='ansible_tower_proot_', dir=settings.AWX_PROOT_BASE_PATH)
|
||||
os.chmod(path, stat.S_IRUSR | stat.S_IWUSR | stat.S_IXUSR)
|
||||
return path
|
||||
|
||||
|
||||
@@ -352,6 +352,9 @@ AWX_PROOT_SHOW_PATHS = []
|
||||
# Number of jobs to show as part of the job template history
|
||||
AWX_JOB_TEMPLATE_HISTORY = 10
|
||||
|
||||
# The directory in which proot will create new temporary directories for its root
|
||||
AWX_PROOT_BASE_PATH = "/tmp"
|
||||
|
||||
# Default list of modules allowed for ad hoc commands.
|
||||
AD_HOC_COMMANDS = [
|
||||
'command',
|
||||
|
||||
Reference in New Issue
Block a user