Trac with proxy server
From DreamHost
This is a tutorial to get Trac (behind tracd) working with an Apache-hosted DreamHost site on DreamHost VPS/DS (only tested VPS).
Why would I proxy Trac? It supports FastCGI!
- Trac/FastCGI is slightly slower than Trac/tracd
- Trac/tracd is more lightweight and conserves resources (compare 30MB with one fastcgi trac to 13MB-21MB with tracd)
- Most FastCGI setups involve playing with configure scripts and even more playing with for logins, with this you don't have to
Alright, now show me!
- Create your environment(s) with trac-admin
- if you want more than one environment, remember to append -e to the tracd command line and make your environments in a subfolder of the parent folder; eg.
- trac-envs/
- myawesomeproject1
- myawesomeproject2
- trac-envs/
- if you want more than one environment, remember to append -e to the tracd command line and make your environments in a subfolder of the parent folder; eg.
- Create an .htpasswd file (should not be public): htpasswd -c mypasswdfile myuser
- Run tracd (in a screen): tracd -p 23234 --basic-auth="*,/home/YOURUSER/mypaswdfile,Trac Login" /home/YOURUSER/trac-env/
- change the port (-p) to something else
- add -s if you are hosting a single project -- it'll skip the listing you normally get
- if want to be able to have your changes live Ctrl-C and re-run the command (hint: pressing up in most shells will help you get the command) or use -r (not recommended)
- Add the configuration for it to https://panel.dreamhost.com/index.cgi?tree=domain.proxy&
- Should be obvious :) For those who don't know:
- Under Set Up A Proxy Server Port, enter the value you gave to -p as "Port Number to Proxy:" and deal with the proxied domain part. Here's an example:
- Should be obvious :) For those who don't know:
