mirror of
https://github.com/ansible/awx.git
synced 2026-01-10 15:32:07 -03:30
Updated wsgi.py to get the lib path from distutils.sysconfig
* also re-added the WSGISocketPrefix line to the apache config, since that was broken on RHEL systems, however it is now changed to be in /var/run instead of just run (relative to the httpd root) which didn't work on Ubuntu systems.
This commit is contained in:
parent
80afb2e08d
commit
956b076e5b
@ -13,12 +13,13 @@ https://docs.djangoproject.com/en/dev/howto/deployment/wsgi/
|
||||
import os
|
||||
import sys
|
||||
from awx import MODE
|
||||
from distutils.sysconfig import get_python_lib
|
||||
|
||||
# Update the default settings environment variable based on current mode.
|
||||
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'awx.settings.%s' % MODE)
|
||||
|
||||
# Add local site-packages directory to path.
|
||||
local_site_packages = os.path.join(os.path.dirname(__file__), 'lib',
|
||||
local_site_packages = os.path.join(get_python_lib(), 'awx', 'lib',
|
||||
'site-packages')
|
||||
sys.path.insert(0, local_site_packages)
|
||||
|
||||
|
||||
@ -1,4 +1,5 @@
|
||||
NameVirtualHost *:80
|
||||
WSGISocketPrefix /var/run/wsgi
|
||||
|
||||
<VirtualHost _default_:80>
|
||||
ServerName localhost
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user