fedora 19 安装SVN trac
1. 安装Apahce, PHP, MySQL以及php连接mysql库组件。
#yum -y install httpd php mysql mysql-server php-mysql
2. 安装apache扩展
#yum -y install httpd-manual mod_ssl mod_perl mod_auth_mysql
3. 配置开机启动服务
#/sbin/chkconfig httpd on [设置apache服务器httpd服务开机启动]#/sbin/service httpd start [启动httpd服务,与开机启动无关]
4.安装subversion
#yum install subversion
5. 安装SVN所需module:
#yum install mod_dav_svn subversion-python
6. 添加用户
#htpasswd -cm /etc/httpd/conf/authfile testuser
New password:
Re-type new password:
Adding password for user testuser
## Create testuser2 ##
#htpasswd -m/etc/httpd/conf/authfile testuser2
New password:
Re-type new password:
Adding password for user testuser2
7.安装完毕之后发现,在/etc/httpd/conf.d下创建subversion.conf, 修改subversion.conf,如下:
<Location /svn>
DAV svnSVNPath /var/www/svnAuthType BasicAuthName "Subversion repositories"AuthUserFile /etc/httpd/conf/authfileRequire valid-userSVNAdvertiseV2Protocol Off</Location>其中,SVNPath是所有Repository的根目录.8.创建subversion版本库:#mkdir/var/www/svn#svnadmin create/var/www/svn#chown -R apache.apache/var/www/svn##更改apache权限#chcon -R -t httpd_sys_content_t/var/www/svn#chcon -R -t httpd_sys_rw_content_t/var/www/svn9.配置repository权限打开/var/www/svn/conf/svnserve.conf文件:10.重启服务器:
anon-access = nonepassword-db = passwd
authz-db = authz#service httpd restart
11.测试http://localhost/svn/
12.安装trac
#yum install trac
13. trac初始化:#mkdir/var/www/trac
#trac-admin/var/www/trac initenv
14.编辑trac.ini
#vi /var/www/trac/conf/trac.ini
将repository_dir=/var/www/svn
15.现在创建一个管理员用户,赋予他trac_admin的权限:authz_file = /etc/httpd/conf.d/authfile
#trac-admin/var/www/trac permission add admin TRAC_ADMIN
16.启动trac
#tracd -d --port 8000 --basic-auth="*,/etc/httpd/conf.d/authfile,"/var/www/trac
打开http://127.0.0.1:8000/trac/
17.配置trac
将管理里的插件关于Subversion的全部应用