opensuse10.3上搭建svn服务器
出自:http://www.rocrocket.cn/?p=96
suse发行版本和fedora的区别可真是不小阿~开源社区需要配置一台svn服务器,搞了好久,才熟悉了suse的环境,包括如何配置yast源,如何修改系统设置等等~最终配置成功:D 教程如下:
准备阶段
首先需要保证系统中有如下的包:
apache2, apache2-doc, apache2-prefork, libapr1, libapr-util1, neon, subversion, subversion-server
要获得如上的这些包 需要配置yast源来安装这些包。
加入一个新的yast源:(举例)
zypper addrepo http://210.25.132.176/distro suse_roc
suse_roc为软件源的别名,可以自己定义
之后执行命令yast进入管理界面,选择software management,系统就会自己来查找和检索验证软件源了。
完成之后,就可以使用tab来选择search安装如上的软件了。
关于源的操作:
加入源:zypper addrepo zypper addrepo http://210.25.132.176/distro suse_roc
删除源:zypper rr ‘openSUSE-10.3-DVD 10.3′
配置阶段
建立svn用户组和svn用户
(su) groupadd -r svn
useradd -r -g svn -m -d /srv/svn -s /bin/false svn加载svn模块:
(su) a2enmod dav
(su) a2enmod dav_svn修改/etc/apache2/conf.d/subversion.conf文件为如下形式:
复制内容到剪贴板
代码:
# Example configuration for a subversion repository
# see /usr/share/doc/packages/subversion for the full documentation
<IfModule mod_dav_svn.c>
# Set up single repository directory ‘kdrepos’
# This has open read access, but limited write (commit) access
<Location /BOSS>
DAV svn
SVNParentPath /srv/svn/BOSS
# Allow the ‘kdrepos’ index page to list all the repositories it contains
SVNListParentPath On
# Limit write permission to list of valid users.
<LimitExcept GET PROPFIND OPTIONS REPORT>
# Require SSL connection for password protection.
# SSLRequireSSL
AuthType Basic
# Message to give to the committer
AuthName “Write access requires a password”
# File listing users with write (commit) access
AuthUserFile /srv/svn/user_access/BOSS_passwdfile
Require valid-user
</LimitExcept>
</Location>
# Set up stricter conditions for one directory within the ‘kdrepos’ dir:
# ’secret_repo’ has limited write access, and also limited read access.
<Location /BOSS/secret_repo>
Require valid-user
</Location>
</IfModule>