mirror of
https://github.com/ansible/awx.git
synced 2026-04-10 20:49:24 -02:30
Preliminary EL6 SCL Python 2.7 support
This commit is contained in:
@@ -17,6 +17,7 @@ recursive-exclude awx/settings local_settings.py*
|
|||||||
include tools/scripts/request_tower_configuration.sh
|
include tools/scripts/request_tower_configuration.sh
|
||||||
include tools/scripts/request_tower_configuration.ps1
|
include tools/scripts/request_tower_configuration.ps1
|
||||||
include tools/scripts/ansible-tower-service
|
include tools/scripts/ansible-tower-service
|
||||||
|
include tools/scripts/tower-python
|
||||||
include tools/munin_monitors/*
|
include tools/munin_monitors/*
|
||||||
include tools/sosreport/*
|
include tools/sosreport/*
|
||||||
include COPYING
|
include COPYING
|
||||||
|
|||||||
21
Makefile
21
Makefile
@@ -265,30 +265,21 @@ requirements requirements_ansible requirements_dev requirements_jenkins: %: real
|
|||||||
real-requirements_ansible: virtualenv
|
real-requirements_ansible: virtualenv
|
||||||
if [ "$(VENV_BASE)" ]; then \
|
if [ "$(VENV_BASE)" ]; then \
|
||||||
. $(VENV_BASE)/ansible/bin/activate; \
|
. $(VENV_BASE)/ansible/bin/activate; \
|
||||||
fi; \
|
fi && \
|
||||||
pip install -r requirements/requirements_ansible.txt; \
|
pip install -r requirements/requirements_ansible.txt
|
||||||
if [ "$(VENV_BASE)" ]; then \
|
|
||||||
deactivate; \
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Install third-party requirements needed for Tower's environment.
|
# Install third-party requirements needed for Tower's environment.
|
||||||
real-requirements: requirements_ansible
|
real-requirements: requirements_ansible
|
||||||
if [ "$(VENV_BASE)" ]; then \
|
if [ "$(VENV_BASE)" ]; then \
|
||||||
. $(VENV_BASE)/tower/bin/activate; \
|
. $(VENV_BASE)/tower/bin/activate; \
|
||||||
fi; \
|
fi && \
|
||||||
pip install -r requirements/requirements.txt; \
|
pip install -r requirements/requirements.txt; \
|
||||||
if [ "$(VENV_BASE)" ]; then \
|
|
||||||
deactivate; \
|
|
||||||
fi
|
|
||||||
|
|
||||||
real-requirements_dev: requirements_ansible
|
real-requirements_dev: requirements_ansible
|
||||||
if [ "$(VENV_BASE)" ]; then \
|
if [ "$(VENV_BASE)" ]; then \
|
||||||
. $(VENV_BASE)/tower/bin/activate; \
|
. $(VENV_BASE)/tower/bin/activate; \
|
||||||
fi; \
|
fi && \
|
||||||
pip install -r requirements/requirements_dev.txt; \
|
pip install -r requirements/requirements_dev.txt
|
||||||
if [ "$(VENV_BASE)" ]; then \
|
|
||||||
deactivate; \
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Install third-party requirements needed for running unittests in jenkins
|
# Install third-party requirements needed for running unittests in jenkins
|
||||||
real-requirements_jenkins:
|
real-requirements_jenkins:
|
||||||
@@ -859,7 +850,7 @@ build:
|
|||||||
$(PYTHON) setup.py build
|
$(PYTHON) setup.py build
|
||||||
|
|
||||||
install:
|
install:
|
||||||
export SCL_PREFIX
|
export SCL_PREFIX HTTPD_SCL_PREFIX
|
||||||
$(PYTHON) setup.py install $(SETUP_INSTALL_ARGS)
|
$(PYTHON) setup.py install $(SETUP_INSTALL_ARGS)
|
||||||
|
|
||||||
# Docker Compose Development environment
|
# Docker Compose Development environment
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
NameVirtualHost *:443
|
NameVirtualHost *:443
|
||||||
WSGISocketPrefix /var/run/wsgi
|
WSGISocketPrefix /var/run/wsgi
|
||||||
|
WSGIPythonHome /var/lib/awx/venv/tower
|
||||||
|
|
||||||
# LoadModule ssl_module modules/mod_ssl.so
|
# LoadModule ssl_module modules/mod_ssl.so
|
||||||
|
|
||||||
<VirtualHost _default_:443>
|
<VirtualHost _default_:443>
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
WSGISocketPrefix /var/run/wsgi
|
WSGISocketPrefix /var/run/wsgi
|
||||||
|
WSGIPythonHome /var/lib/awx/venv/tower
|
||||||
|
|
||||||
<VirtualHost _default_:80>
|
<VirtualHost _default_:80>
|
||||||
|
|
||||||
|
|||||||
@@ -1,17 +1,12 @@
|
|||||||
|
Alias /munin /var/www/html/munin/
|
||||||
Alias /munin /var/cache/munin/www
|
<Directory /var/www/html/munin/>
|
||||||
<Directory /var/cache/munin/www>
|
|
||||||
Order Allow,Deny
|
Order Allow,Deny
|
||||||
Allow from all
|
Allow from all
|
||||||
Options FollowSymLinks
|
|
||||||
|
|
||||||
AuthUserFile /var/lib/awx/.munin_htpasswd
|
AuthUserFile /var/lib/awx/.munin_htpasswd
|
||||||
AuthName "Munin"
|
AuthName "Munin"
|
||||||
AuthType Basic
|
AuthType Basic
|
||||||
require valid-user
|
require valid-user
|
||||||
|
|
||||||
<IfModule mod_expires.c>
|
</Directory>
|
||||||
ExpiresActive On
|
ScriptAlias /munin-cgi/munin-cgi-graph /var/www/cgi-bin/munin-cgi-graph
|
||||||
ExpiresDefault M310
|
|
||||||
</IfModule>
|
|
||||||
</Directory>
|
|
||||||
@@ -70,7 +70,7 @@ os-client-config==1.14.0
|
|||||||
os-diskconfig-python-novaclient-ext==0.1.3
|
os-diskconfig-python-novaclient-ext==0.1.3
|
||||||
os-networksv2-python-novaclient-ext==0.25
|
os-networksv2-python-novaclient-ext==0.25
|
||||||
os-virtual-interfacesv2-python-novaclient-ext==0.19
|
os-virtual-interfacesv2-python-novaclient-ext==0.19
|
||||||
pbr==0.11.1
|
pbr==1.8.1
|
||||||
oslo.config==3.3.0
|
oslo.config==3.3.0
|
||||||
oslo.i18n==3.2.0
|
oslo.i18n==3.2.0
|
||||||
oslo.serialization==2.2.0
|
oslo.serialization==2.2.0
|
||||||
|
|||||||
@@ -34,7 +34,7 @@ os-client-config==1.14.0
|
|||||||
os-diskconfig-python-novaclient-ext==0.1.3
|
os-diskconfig-python-novaclient-ext==0.1.3
|
||||||
os-networksv2-python-novaclient-ext==0.25
|
os-networksv2-python-novaclient-ext==0.25
|
||||||
os-virtual-interfacesv2-python-novaclient-ext==0.19
|
os-virtual-interfacesv2-python-novaclient-ext==0.19
|
||||||
pbr==0.11.1
|
pbr==1.8.1
|
||||||
oslo.config==3.3.0
|
oslo.config==3.3.0
|
||||||
oslo.i18n==3.2.0
|
oslo.i18n==3.2.0
|
||||||
oslo.serialization==2.2.0
|
oslo.serialization==2.2.0
|
||||||
|
|||||||
15
setup.py
15
setup.py
@@ -19,19 +19,20 @@ else:
|
|||||||
|
|
||||||
# Path prefix for when we're running under a software collection
|
# Path prefix for when we're running under a software collection
|
||||||
scl_prefix = os.getenv('SCL_PREFIX', '')
|
scl_prefix = os.getenv('SCL_PREFIX', '')
|
||||||
|
httpd_scl_prefix = os.getenv('HTTPD_SCL_PREFIX', scl_prefix)
|
||||||
|
|
||||||
# Paths we'll use later
|
# Paths we'll use later
|
||||||
etcpath = scl_prefix + "/etc/tower"
|
etcpath = "/etc/tower"
|
||||||
homedir = "/var/lib/awx"
|
homedir = "/var/lib/awx"
|
||||||
|
bindir = "/usr/bin"
|
||||||
sharedir = scl_prefix + "/usr/share/awx"
|
sharedir = scl_prefix + "/usr/share/awx"
|
||||||
bindir = scl_prefix + "/usr/bin"
|
|
||||||
docdir = scl_prefix + "/usr/share/doc/ansible-tower"
|
docdir = scl_prefix + "/usr/share/doc/ansible-tower"
|
||||||
munin_plugin_path = "/etc/munin/plugins/"
|
munin_plugin_path = "/etc/munin/plugins/"
|
||||||
munin_plugin_conf_path = "/etc/munin/plugin-conf.d"
|
munin_plugin_conf_path = "/etc/munin/plugin-conf.d"
|
||||||
|
|
||||||
if os.path.exists("/etc/debian_version"):
|
if os.path.exists("/etc/debian_version"):
|
||||||
sysinit = scl_prefix + "/etc/init.d"
|
sysinit = scl_prefix + "/etc/init.d"
|
||||||
webconfig = scl_prefix + "/etc/apache2/conf.d"
|
webconfig = httpd_scl_prefix + "/etc/apache2/conf.d"
|
||||||
shutil.copy("config/awx-munin-ubuntu.conf", "config/awx-munin.conf")
|
shutil.copy("config/awx-munin-ubuntu.conf", "config/awx-munin.conf")
|
||||||
# sosreport-3.1 (and newer) look in '/usr/share/sosreport/sos/plugins'
|
# sosreport-3.1 (and newer) look in '/usr/share/sosreport/sos/plugins'
|
||||||
# sosreport-3.0 looks in '/usr/lib/python2.7/dist-packages/sos/plugins'
|
# sosreport-3.0 looks in '/usr/lib/python2.7/dist-packages/sos/plugins'
|
||||||
@@ -39,7 +40,7 @@ if os.path.exists("/etc/debian_version"):
|
|||||||
sosconfig = "/usr/share/sosreport/sos/plugins"
|
sosconfig = "/usr/share/sosreport/sos/plugins"
|
||||||
else:
|
else:
|
||||||
sysinit = scl_prefix + "/etc/rc.d/init.d"
|
sysinit = scl_prefix + "/etc/rc.d/init.d"
|
||||||
webconfig = scl_prefix + "/etc/httpd/conf.d"
|
webconfig = httpd_scl_prefix + "/etc/httpd/conf.d"
|
||||||
shutil.copy("config/awx-munin-el.conf", "config/awx-munin.conf")
|
shutil.copy("config/awx-munin-el.conf", "config/awx-munin.conf")
|
||||||
# The .spec will create symlinks to support multiple versions of sosreport
|
# The .spec will create symlinks to support multiple versions of sosreport
|
||||||
sosconfig = "/usr/share/sosreport/sos/plugins"
|
sosconfig = "/usr/share/sosreport/sos/plugins"
|
||||||
@@ -139,7 +140,8 @@ setup(
|
|||||||
"tools/munin_monitors/mongo_mem",
|
"tools/munin_monitors/mongo_mem",
|
||||||
"tools/munin_monitors/mongo_ops"]),
|
"tools/munin_monitors/mongo_ops"]),
|
||||||
("%s" % munin_plugin_conf_path, ["config/awx_munin_tower_jobs"]),
|
("%s" % munin_plugin_conf_path, ["config/awx_munin_tower_jobs"]),
|
||||||
("%s" % bindir, ["tools/scripts/ansible-tower-service"]),
|
("%s" % bindir, ["tools/scripts/ansible-tower-service",
|
||||||
|
"tools/scripts/tower-python"]),
|
||||||
("%s" % sosconfig, ["tools/sosreport/tower.py"])]),
|
("%s" % sosconfig, ["tools/sosreport/tower.py"])]),
|
||||||
options = {
|
options = {
|
||||||
'egg_info': {
|
'egg_info': {
|
||||||
@@ -149,5 +151,8 @@ setup(
|
|||||||
'dev_build': 'clean --all egg_info sdist',
|
'dev_build': 'clean --all egg_info sdist',
|
||||||
'release_build': 'clean --all egg_info -b "" sdist',
|
'release_build': 'clean --all egg_info -b "" sdist',
|
||||||
},
|
},
|
||||||
|
'build_scripts': {
|
||||||
|
'executable': '/usr/bin/tower-python',
|
||||||
|
},
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user