smallroomsoftware.com

Trac 0.11 installation on Centos/Fedora

Posted on February 14, 2008

How come every time I install trac I do it a different way? Mostly, I'm installing on Centos or Fedora these days. The RPMs available rpmforge only go up to trac 0.10. It seems sensible to go with the 0.11 beta for a new installation - the trac admin web UI is included by default, there are fewer dependencies and the default ticket workflow has changed a bit. After some fiddling about with the manual download, realising that trac.cgi is missing (maybe it's deprecated) I realised that installation is fairly straightforward if you get setuptools (some strange python "egg" installer) and use modpython rather than cgi/fcgi (it's more efficient and easier anyway).

So here are my steps so I don't forget them:

# As root
wget http://peak.telecommunity.com/dist/ez_setup.py
python ez_setup.py

easy_install Pygments
easy_install Genshi
easy_install Trac

trac-admin /srv/trac/myproject initenv
chown -R apache:apache /srv/trac/myproject

nano /etc/httpd.d/trac.conf

# And add something like:

<Location "/trac">
  SetHandler mod_python
  PythonInterpreter main_interpreter
  PythonHandler trac.web.modpython_frontend 
  PythonOption TracEnvParentDir /srv/trac
  PythonOption TracUriRoot /trac

  # The following gives basic HTTP authentication
  AuthType Basic
  AuthName "Trac"
  AuthUserFile /srv/users.htpasswd
  Require valid-user

  # ... which should be used with SSL:
  SSLRequireSSL
</Location>

service httpd restart
Comments
  1. AserdpMay 22, 2008 @ 10:28 PM
    Nice post. Correction: chmod -R apache:apache /srv/trac/myproject should be chown -R apache:apache /srv/trac/myproject
  2. tomJuly 22, 2008 @ 03:06 PM
    Fixed! Cheers!
  3. kiran aghorAugust 22, 2008 @ 04:55 AM
    Thanks a million :). These instructions are what I needed.
Post a comment
Comment



If you can read this, you don't use a typical webbrowser that plays nice with CSS.
Please do not fill in anything here!



Hosting by site5.com