PDA

View Full Version : Trac + Litespeed


zhesto
06-29-2006, 10:25 PM
Hi, I installed Trac on my ubuntu dapper box, following these instructions (http://projects.edgewall.com/trac/wiki/TracLitespeed). Everything working very well. Just there is still one more step - how to trigger HTTP Authentication box on /projects/xxxxx/login. With Apache it is releazed with:

<Location "/proj/login">
AuthType Basic
AuthName "project"
AuthUserFile /var/www/trac.htpasswd
Require valid-user
</Location>

See: Debian Sarge Trac Install (http://projects.edgewall.com/trac/wiki/TracOnDebianSarge)

I tryed first to do this just for one project (fixed /projects/name/login. But what context to create?
- "Static"? - it's maping url to directory
- "CGI"? - it's mapping url to directory with cgi-bin scripts

So how to do Location-like stuff with Litespeed?

And the second stage is to do the same for multiply projects ( /projects/.../login ) but maybe i can create different context entry for every project.

mistwang
06-30-2006, 09:54 AM
I think it should be a CGI context, the context type should follow its parent context to make a context works just like "location" in Apache.
However, when I tried a single project Trac setup, I used FastCGI instead of CGI for better performance. Not sure how to implement that on a multiple project setup though.

mistwang
06-30-2006, 10:44 AM
You should define a CGI context with URI /trac.cgi/login, location is the same, pointing to trac.cgi, as the URL has been rewritten to "/trac.cgi/login", not "/projects/...." any more.

Just take a closer look at the Howto, it is possible to replace the CGI setup with FCGI setup, just add a FCGI app with trac.fcgi, add a FCGI context with URI /trac.fcgi, change the rewrite rule from /trac.cgi to /trac.fcgi.