View Single Post
  #8  
Old 2nd November 2008, 14:43
quentusrex quentusrex is offline
Senior Member
 
Join Date: May 2008
Posts: 174
Thanks: 6
Thanked 11 Times in 7 Posts
Default

Awesome. We'll see how it goes. here is my initial tutorial/build of the system. It allows for one install of trac and svn on the server, then allows easy install for each individual client. Thus it will be easy to add into a module to allow a user to have access to. :-D

This install is still rough. I need to test it a few more times, but it seems to work. It is initially designed to host a single project, but can easily be changed to host multiple projects.



1. sudo apt-get install apache2 libapache2-mod-python subversion-tools libapache2-svn python-setuptools subversion python-subversion

2. sudo easy_install Trac

3. sudo mkdir /var/clients/client1/web1/trac

4. sudo chown web1:client1 /var/clients/client1/web1/trac

5. vim /etc/apache2/sites-enabled/mydomain.vhost

Add the following near the end, but above the </VirtualHost>
================================

<Location /trac>
SetHandler mod_python
PythonInterpreter main_interpreter
PythonHandler trac.web.modpython_frontend
PythonOption TracEnv /var/clients/client1/web1/trac/testproject
PythonOption TracUriRoot /trac/testproject
PythonOption PYTHON_EGG_CACHE /tmp
</Location>

<Location /trac/login>
AuthType Basic
AuthName "myproject"
AuthUserFile /var/clients/client1/web1/trac/.passwd
Require valid-user
</Location>


<Location /svn>
DAV svn
AuthType Basic
AuthName "My Trac"
AuthUserFile /var/clients/client1/web1/svn/.passwd
AuthzSVNAccessFile /var/local/svn/svn.example.com/conf/authz
SVNPath /var/local/svn/svn.example.com
Require valid-user
</Location>

================================

6. sudo mkdir /var/clients/client1/web1/svn

7. sudo chown web1:client1 /var/clients/client1/web1/svn

8. sudo svnadmin create /var/clients/client1/web1/svn/<YourProjectNameHere>

9. sudo chown -R web1:client1 /var/clients/client1/web1/svn

10. sudo /etc/init.d/apache2 reload

11. sudo trac-admin /var/clients/client1/web1/trac/<YourProjectNameHere> initenv <projectname> sqlite:db/trac.db svn /var/clients/client1/web1/svn/<YourProjectNameHere>

12. sudo chown -R web1:client1 /var/clients/client1/web1/trac

13. sudo apt-get install build-essential graphviz htmldoc enscript

14. sudo rm /var/clients/client1/web1/svn/.passwd

15. sudo touch /var/clients/client1/web1/svn/.passwd

14. sudo rm /var/clients/client1/web1/trac/.passwd

15. sudo touch /var/clients/client1/web1/trac/.passwd

(so that trac can manage it's own users)
16. sudo chown web1:client1 /var/clients/client1/web1/trac/.passwd

17. Now some trac plugins:
sudo easy_install http://svn.edgewall.org/repos/genshi/trunk/
sudo easy_install http://trac-hacks.org/svn/accountmanagerplugin/trunk
sudo easy_install http://trac-hacks.org/svn/customfieldadminplugin/0.11
sudo easy_install http://trac-hacks.org/svn/eclipsetra...racrpcext/0.10
sudo easy_install http://trac-hacks.org/svn/iniadminplugin/0.11
sudo easy_install http://trac-hacks.org/svn/masterticketsplugin/0.11
sudo easy_install http://trac-hacks.org/svn/pagetopdfplugin/0.10/
sudo easy_install http://trac-hacks.org/svn/progressmetermacro/0.11
sudo easy_install http://trac-hacks.org/svn/ticketdeleteplugin/0.11
sudo easy_install http://trac-hacks.org/svn/tracwysiwygplugin/0.11
sudo easy_install http://wikinotification.ufsoft.org/svn/trunk

18. htpasswd /var/clients/client1/web1/svn/.passwd <username>

19. htpasswd /var/clients/client1/web1/trac/.passwd <username>

20. trac-admin /var/clients/client1/web1/trac/<YourProjectNameHere> permission add <username> TRAC_ADMIN

21. /etc/init.d/apache2 restart

Last edited by quentusrex; 2nd November 2008 at 15:01.
Reply With Quote