Edgewall Software

Changes between Version 12 and Version 13 of TracModWSGI


Ignore:
Timestamp:
Sep 23, 2008, 2:51:44 PM (16 years ago)
Author:
osimons
Comment:

Adding a tiny wsgi application for testing setup.

Legend:

Unmodified
Added
Removed
Modified
  • TracModWSGI

    v12 v13  
    4444Here, the script is in a subdirectory of the Trac environment. In order to let Apache run the script, access to the directory in which the script resides is opened up to all of Apache. Additionally, Trac is always run in the first Python interpreter created by mod_wsgi; this is necessary because the Subversion Python bindings, which are used by Trac, don't always work in other subinterpreters and may crash Apache as a result. After adding this configuration, restart Apache, and then it should work.
    4545
     46To test the setup of Apache, mod_wsgi and Python itself (ie. without involving Trac and dependencies), this simple wsgi application can be used to make sure that requests gets served (use as only content in your .wsgi script):
     47
     48{{{
     49def application(environ, start_response):
     50        start_response('200 OK',[('Content-type','text/html')])
     51        return ['<html><body>Hello World!</body></html>']
     52}}}
     53
    4654See also the mod_wsgi [http://code.google.com/p/modwsgi/wiki/IntegrationWithTrac installation instructions] for Trac.
    4755