| 1 | = Trac and FastCGI = |
| 2 | |
| 3 | There is a patch to Trac 0.8.1 available adding support for the [http://www.fastcgi.com/ FastCGI] interface. Like TracModPython, this allows trac to remain resident, and is faster than external CGI interfaces which must start a new process for each page view. However, unlike mod_python, it is able to support [http://httpd.apache.org/docs/suexec.html SuEXEC]. Additionaly, it is supported by much wider variety of webservers. |
| 4 | |
| 5 | == The patch == |
| 6 | |
| 7 | * http://bdash.net.nz/files/trac-fcgi-0.patch |
| 8 | * [http://article.gmane.org/gmane.comp.version-control.subversion.trac.general/2294 Mailing List thread] |
| 9 | |
| 10 | == Simple configuration == |
| 11 | {{{ |
| 12 | # Enable fastcgi for .fcgi files |
| 13 | # if using a distro package for mod_fcgi, something like this is probably already done |
| 14 | <IfModule mod_fastcgi.c> |
| 15 | AddHandler fastcgi-script .fcgi |
| 16 | FastCgiIpcDir /var/lib/apache2/fastcgi |
| 17 | </IfModule> |
| 18 | LoadModule fastcgi_module /usr/lib/apache2/modules/mod_fastcgi.so |
| 19 | }}} |
| 20 | |
| 21 | You can either setup the TRAC_ENV as an overall default: |
| 22 | {{{ |
| 23 | FastCgiConfig -initial-env TRAC_ENV=/path/to/env/trac |
| 24 | }}} |
| 25 | Or '''NOT VERIFIED''' you should be able to do it per-directory as described in TracInstall for normal CGIs. |
| 26 | |
| 27 | Configure ScriptAlias or similr options as described in TracInstall, but calling cgi-bin/trac.fcgi instead of cgi-bin/trac.cgi |
| 28 | |
| 29 | ---- |
| 30 | See also TracGuide, TracInstall, TracMultipleProjects |