diff --git a/heliopropa.wsgi b/heliopropa.wsgi new file mode 100644 index 0000000..42bda7f --- /dev/null +++ b/heliopropa.wsgi @@ -0,0 +1,42 @@ +# +# Simple wsgi wrapper to run flask app through apache. +# +# Relies on an apache2 virtualhost configuration. +# See ./resources/apache2-virtual-host.conf +# +# It merely calls the app factory and exports it as +# the application variable. + +# The apache WSGIDaemonProcess allows us to set +# a virtualenv +# a pythonpath + +# Instead we could: +# +## 1- activate venv +# python_home = '/var/www/html/app-web/' +# activate_this = python_home + 'venv/bin/activate_this.py' +# with open(activate_this) as file_: +# exec(file_.read(), dict(__file__=activate_this)) +# +## 2- set a python path +# sys.path.insert(0, '/var/www/html/app-web/') +# +## 3- set some logging facilities +# import logging, sys +# logging.basicConfig(stream=sys.stderr) + +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # + +# +# Main Part +# + +# simply use application already set in main app file +# +from web.run import app as application + + + + +# vim: ft=python -- libgit2 0.21.2