Installation of Trac 0.84

1. pysqlite必须是1.16,不是是2
2. trac 0.84必须是 python 2.3,而不是2.4
3. 将各个组件安装好,包括 python 2.3, clearsilver-0.9.14.win32-py2.3.exe,
pysqlite-1.1.6.win32-py2.3.exe, svn-win32-1.2.3_py.zip,
docutils-0.3.9.rar,and
trac-0.8.4.win32.exe,都很简单。对svn-win32-1.2.3_py.zip解压缩后,将其中的内容copy到
python23/lib下。对doctuils-0.3.9的内容,解压缩后,运行python setup.py install即可自动安装
3. python trac-admin trac-db-name
3.1 using trac-admin trac-db-name to customize settings.
3.2 copy trac/cgi-bin/trac.cgi to apache2/cgi-bin
3.3 add permission to trac: permission add admin TRAC_ADMIN or something like
3.4 httpd.conf的配置
    Alias /trac "/wherever/you/installed/trac/htdocs/"
    <Location "/cgi-bin/trac.cgi">
        SetEnv TRAC_ENV "d:traclabForum.db"
    </Location>

    # You need something like this to authenticate users
    <Location "/cgi-bin/trac.cgi/login">
        AuthType Basic
        AuthName "Rslab forum project"
        AuthUserFile /somewhere/trac.htpasswd
        Require valid-user
    </Location>
4. it might work now!

更将至 0.9b1后,要重新修改apache下的trac.cgi,我因为这个找了很长的原因。
在系统变量的path里增加 c:python23; c:program filessvn-win32-1.2.3/bin。由于apache做为service运行,所以得重启一次。否则trac网页浏览的时候会提示找不着 DLL
如果提示找不着log模块,将trac下的Log.py修改成log.py即可。这是一个已知的bug,可以trac的官方网站找着。

Leave a Reply

Your email address will not be published. Required fields are marked *