当前环境:
trac 0.9.3
apache 2.0.55
mod_python 3.2.5b
建立用户
htpasswd -bcm D:workspaceprojects rac.htaccess martin 1234
为该用户赋项目的权限
python trac-admin D:workspaceprojects rac
Trac [D:workspaceprojects rac]>permission add martin TRAC_ADMIN
Trac [D:workspaceprojects rac]>permission add martin TRAC_ADMIN
修改apache的httd.conf (具体可见这里:http://projects.edgewall.com/trac/wiki/TracModPython)
添加:
LoadModule python_module modules/mod_python.so
<Location /xpost>
SetHandler mod_python
PythonHandler trac.web.modpython_frontend
PythonOption TracEnv D:/workspace/projects/trac
Location>
<Location "/xpost/login">
AuthType Basic
AuthName "XPost Login"
AuthUserFile D:/workspace/projects/trac/.htaccess
Require valid-user
Location>
SetHandler mod_python
PythonHandler trac.web.modpython_frontend
PythonOption TracEnv D:/workspace/projects/trac
Location>
<Location "/xpost/login">
AuthType Basic
AuthName "XPost Login"
AuthUserFile D:/workspace/projects/trac/.htaccess
Require valid-user
Location>
ok,重起apache就可以了
没有评论:
发表评论