wiki:TipAndDoc/network/httpd/svn-trac

templates and conf file sample

setup Apache and its modules

  • sudo aptitude install -R apache2 libapache2-svn libapache2-mod-fcgid
  • sudo a2enmod ssl

activate lab.mitty.jp

install Subversion

  • sudo aptitude install -R -y subversion

install Trac

install packages for Trac

  • sudo aptitude install -R -y python-setuptools
  • sudo easy_install -U setuptools
  • sudo aptitude install -R -y python-subversion
  • sudo aptitude install -R -y enscript
  • sudo easy_install Pygments
  • sudo aptitude install -R -y unzip

i18n

  • sudo easy_install pytz
  • sudo easy_install Babel

install Trac itself

install plugins

trachacks:graphviz

  • sudo aptitude install -R -y graphviz
  • sudo aptitude install -R ttf-vlgothic
  • svn co http://trac-hacks.org/svn/graphvizplugin
  • vim graphvizplugin/0.11/graphviz/graphviz.py
    • 0.11/graphviz/graphviz.py

       
      2020import locale 
      2121import os 
      2222import re 
      23 import sha 
       23import hashlib 
      2424import subprocess 
      2525import sys 
      2626 
       
      310310        encoded_cmd = (processor + unicode(self.processor_options)) \ 
      311311                .encode(self.encoding) 
      312312        encoded_content = content.encode(self.encoding) 
      313         sha_key  = sha.new(encoded_cmd + encoded_content).hexdigest() 
       313        sha_key  = hashlib.sha1(encoded_cmd + encoded_content).hexdigest() 
      314314        img_name = '%s.%s.%s' % (sha_key, processor, out_format) 
      315315        # cache: hash.<dot>.<png> 
      316316        img_path = os.path.join(self.cache_dir, img_name) 
  • sudo mkdir /var/tmp/graphviz
  • sudo chgrp www-data /var/tmp/graphviz
  • sudo chmod g+w /var/tmp/graphviz
  • ~/graphvizplugin/0.11$ python setup.py bdist_egg
  • ~/graphvizplugin/0.11$ sudo cp dist/graphviz-0.7.6dev-py2.6.egg /home/tools/trac/plugins/

track-hacks:XmlRpcPlugin

  • svn co http://trac-hacks.org/svn/xmlrpcplugin/
  • ~/xmlrpcplugin/trunk$ python setup.py bdist_egg
  • ~/xmlrpcplugin/trunk$ sudo cp dist/TracXMLRPC-1.1.0_r9395-py2.6.egg /home/systool/trac/plugins/
  • sudo vim /home/systool/trac/conf/trac.ini

create repository/project

Last modified 4 years ago Last modified on Nov 27, 2013 10:12:21 PM