1 The WSGI examples provide support for the wsgiref.simple_server module
2 (available in Python 2.5 and later) and the WSGI CGI handler code found in PEP
3 333 and placed in the wsgi_cgi module. Deploying in other environments would
4 require slightly different "glue code" to be written.
5
6 Deploying with wsgiref.simple_server
7 ====================================
8
9 The examples/WSGI/*App.py programs (eg. examples/WSGI/SimpleApp.py) can be run
10 directly - these will employ the WSGI server in the Python standard library.
11
12 Deploying in CGI Environments
13 =============================
14
15 Declare the script in httpd.conf or equivalent Web server configuration file.
16 For example:
17
18 ScriptAlias /wsgi/simple "/home/paulb/Software/Python/WebStack/examples/WSGI/SimpleHandler.py"
19
20 The WebStack package must reside on the PYTHONPATH, along with the package
21 containing the application itself. Therefore, ensure that the handler uses the
22 appropriate entries in sys.path.
23
24 Ensure that the handler file for the application has the appropriate
25 permissions:
26
27 chmod u+x examples/WSGI/SimpleHandler.py