Changes between Version 1 and Version 2 of TracModWSGI

Show
Ignore:
Timestamp:
08/11/09 08:16:13 (5 years ago)
Author:
trac
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • TracModWSGI

    v1 v2  
    7070 
    7171Now Trac drops the connection after serving a page and the connection count on the database will be kept minimal. 
     72 
     73== Getting Trac to work nicely with SSPI and 'Require Group' == 
     74If like me you've set Trac up on Apache, Win32 and configured SSPI, but added a 'Require group' option to your apache configuration, then the SSPIOmitDomain option is probably not working.  If its not working your usernames in trac are probably looking like 'DOMAIN\user' rather than 'user'. 
     75 
     76This WSGI script 'fixes' things, hope it helps: 
     77{{{ 
     78import os 
     79import trac.web.main 
     80 
     81os.environ['TRAC_ENV'] = '/usr/local/trac/mysite' 
     82os.environ['PYTHON_EGG_CACHE'] = '/usr/local/trac/mysite/eggs' 
     83 
     84def application(environ, start_response): 
     85    if "\\" in environ['REMOTE_USER']: 
     86        environ['REMOTE_USER'] = environ['REMOTE_USER'].split("\\", 1)[1] 
     87    return trac.web.main.dispatch_request(environ, start_response) 
     88}}} 
     89---- 
     90See also:  TracGuide, TracInstall, [wiki:TracFastCgi FastCGI], [wiki:TracModPython ModPython], [trac:TracNginxRecipe TracNginxRecipe]