openstack-health/setup.cfg
Matthew Treinish d0a65e31ca
Fix wsgi_script entry point
Previously the wsgi_script openstack-health entry point was pointing
directly to flask app object in the api module. However the script
constructed by pbr attempts to call app and set that as the
application for mod_wsgi. However this is the incorrect usage for a
flask app, and will fail because the app object isn't expected to be
called by itself without any args) Also, according to the flask docs
[1] you just need to set the flask app as the application var in the
to run with mod_wsgi. This commit fixes the wsgi_script entrypoint by
creating a wrapper function which can be called by the generated
output of wsgi scripts from pbr and will return the flask app. This
function is then used as the wsgi_script entrypoint instead of the app
itself. Additionally, this also gives a good injection point if there
are any future initialization or configuration steps that need to be
taken when running.

[1] http://flask.pocoo.org/docs/0.10/deploying/mod_wsgi/#creating-a-wsgi-file

Change-Id: I6e49b4dbbe58e054a28412207b99eb2982a45fbe
2015-10-10 00:39:36 -04:00

39 lines
944 B
INI

[metadata]
name = openstack-health
summary = OpenStack Health Dashboard
description-file =
README.rst
author = OpenStack
author-email = openstack-dev@lists.openstack.org
home-page = http://www.openstack.org/
classifier =
Intended Audience :: Information Technology
Intended Audience :: System Administrators
Intended Audience :: Developers
License :: OSI Approved :: Apache Software License
Operating System :: POSIX :: Linux
Programming Language :: Python
Programming Language :: Python :: 2
Programming Language :: Python :: 2.7
Programming Language :: Python :: 3
Programming Language :: Python :: 3.4
[files]
packages =
openstack_health
[entry_points]
console_scripts =
openstack-health-api = openstack_health.api:main
wsgi_scripts =
openstack-health = openstack_health.api:get_app
[build_sphinx]
all_files = 1
build-dir = doc/build
source-dir = doc/source
[wheel]
universal = 1