在OpenSUSE上搭建基于Web的SVN服务器

上传人:宝路 文档编号:6806530 上传时间:2017-09-13 格式:DOC 页数:14 大小:98.51KB
返回 下载 相关 举报
在OpenSUSE上搭建基于Web的SVN服务器_第1页
第1页 / 共14页
在OpenSUSE上搭建基于Web的SVN服务器_第2页
第2页 / 共14页
在OpenSUSE上搭建基于Web的SVN服务器_第3页
第3页 / 共14页
在OpenSUSE上搭建基于Web的SVN服务器_第4页
第4页 / 共14页
在OpenSUSE上搭建基于Web的SVN服务器_第5页
第5页 / 共14页
点击查看更多>>
资源描述

《在OpenSUSE上搭建基于Web的SVN服务器》由会员分享,可在线阅读,更多相关《在OpenSUSE上搭建基于Web的SVN服务器(14页珍藏版)》请在金锄头文库上搜索。

1、SVN Web server over OpenSUSE在 OpenSUSE 系统上搭建 SVN Web 服务器版本信息 OS: OpenSUSE-11.1 kernel 2.6.27.21-0.1-pae SVN Server: subversion-1.6.15 Web Server: httpd-2.2.17 Perl: perl-v5.10.0 built for i586-linux-thread-multi搭建过程准备 Web Server参见 在 openSUSE 系统上搭建 Apache2 服务器准备 SVN Server 安装。参见 在 openSUSE 系统上搭建 SVN

2、服务器 为 SVN 创建系统用户组/用户ianpub-laptop-ian: sudo /usr/sbin/groupadd -r svnianpub-laptop-ian: sudo /usr/sbin/useradd -r -g svn -d /srv/svn -s /bin/false svn 创建存放 SVN 库的目录ianpub-laptop-ian: sudo mkdir /home/SVN 创建存放 SVN 库 testianpub-laptop-ian: sudo mkdir /home/SVN/testianpub-laptop-ian: sudo svnadmin crea

3、te /home/SVN/testianpub-laptop-ian: sudo chown wwwrun:www /home/SVN/test -R集成 SVN 至 Web 服务 Apache 配置在/usr/local/apache2/conf/http.conf 文件结尾,追加如下内容# Configuration for a subversion repository# see /usr/share/doc/packages/subversion for the full documentation#DAV svnSVNPath /home/SVN/test# Limit write

4、permission to list of valid users.# Require SSL connection for password protection.# SSLRequireSSLAuthType BasicAuthName Write access requires a passwordAuthUserFile /srv/svn/user_access/test_passwdfileRequire valid-user注意:更改配置之后,需要重启 Apache。 设置 SVN 访问权限ianpub-laptop-ian: sudo mkdir /srv/svnianpub-l

5、aptop-ian: sudo mkdir /srv/svn/user_accessianpub-laptop-ian: sudo touch /srv/svn/user_access/test_passwdfileianpub-laptop-ian: sudo chown root:www /srv/svn/user_access/test_passwdfile ianpub-laptop-ian: sudo chmod 640 /srv/svn/user_access/test_passwdfile ianpub-laptop-ian: sudo /usr/local/apache2/bi

6、n/htpasswd /srv/svn/user_access/test_passwdfile ian基本测试在如下环境的下,进行了浏览(无需授权)和提交(需要授权): svn over openSUSE-11.1 TortoiseSVN over Win32在如下环境的下,进行了浏览(无需授权): IE over Win32 Chrome-8.0.552.224 over openSUSE-11.1 Firefox/3.0.8 GTB7.1 over openSUSE-11.1高级访问控制参考 http:/svnbook.red- http.conf 中,去除 项。最终结果如下:DAV sv

7、nSVNPath /home/SVN/testAuthType BasicAuthName SVN Repository for testAuthUserFile /srv/svn/user_access/test_passwdfileRequire valid-user按目录授权配置 定义授权控制描述于文件/home/SVN/test/conf/authz。具体内容如下:aliasesgroupsg_admin = iang_all = xfy,jyz,ian/g_admin = rw/trunkg_all = r/shareg_all = rw/privateian = r/private

8、/rppian = rwxfy = rjyz = r/private/mbbian = rwjyz = rw/private/wttxfy = rw/private/uiixfy = rw 在 http.conf 中,使用 AuthzSVNAccessFile 指定/home/SVN/test/conf/authz 为授权控制文件。最终结果如下:DAV svnSVNPath /home/SVN/testAuthType BasicAuthName SVN Repository for testAuthUserFile /srv/svn/user_access/test_passwdfileAu

9、thzSVNAccessFile /home/SVN/test/conf/authz#PerlAuthenHandler IpAuth Require valid-user测试 拥有管理员身份的 ian,可以读取整个库。 (写未测试)ianSuse-hww: svn -username ian co http:/192.168.10.23/repos/test/ websvn-testPassword for ian: A websvn-test/shareA websvn-test/trunkA websvn-test/trunk/test.cA websvn-test/trunk/new_

10、from_win32.txtA websvn-test/privateA websvn-test/private/uiiA websvn-test/private/uii/uii_by_ian.txtA websvn-test/private/mbbA websvn-test/private/rppA websvn-test/private/wttA websvn-test/private/wtt/from_xfy.txtChecked out revision 6. 对根目录没有任何权限的 jzy,不能读取整个库。ianSuse-hww: rm -rf websvn-test/ianSuse

11、-hww: svn -username jyz co http:/192.168.10.23/repos/test/ websvn-testAuthentication realm: http:/192.168.10.23:80 SVN Repository for testPassword for jyz: svn: Server sent unexpected return value (403 Forbidden) in response to OPTIONS request for http:/192.168.10.23/repos/test 对/trunk 具有只读权限、对 /sha

12、re 具有读写权限的 jzy,可以读取这 2 个目录。ianSuse-hww: mkdir websvn-testianSuse-hww: svn -username jyz co http:/192.168.10.23/repos/test/trunk websvn-test/trunkAuthentication realm: http:/192.168.10.23:80 SVN Repository for testPassword for jyz: A websvn-test/trunk/test.cA websvn-test/trunk/new_from_win32.txtCheck

13、ed out revision 6.ianSuse-hww: svn -username jyz co http:/192.168.10.23/repos/test/share websvn-test/shareChecked out revision 6. 对/private 没有任何权限的 jzy,不能读取该目录。ianSuse-hww: svn -username jyz co http:/192.168.10.23/repos/test/private websvn-test/privatesvn: Server sent unexpected return value (403 Fo

14、rbidden) in response to OPTIONS request for http:/192.168.10.23/repos/test/private 对/private/rpp 具有只读权限、对/private/rpp 具有读写权限的 jzy,可以读取这 2 个目录。ianSuse-hww: mkdir websvn-test/privateianSuse-hww: svn -username jyz co http:/192.168.10.23/repos/test/private/mbb websvn-test/private/mbbChecked out revision

15、 6.ianSuse-hww: svn -username jyz co http:/192.168.10.23/repos/test/private/rpp websvn-test/private/rppChecked out revision 6. 对/private/wtt、/private/uii 没有任何权限的 jzy,不能读取这 2 个目录。ianSuse-hww: svn -username jyz co http:/192.168.10.23/repos/test/private/wtt websvn-test/private/wttsvn: Server sent unexpected return value (403 Forbidden) in response to OPTIONS request for http:/192.168.10.23/repos/test/private/wttianSuse-hww: svn -username jyz co http:/192.168.10.23/repos/test/private/uii websvn-test/private/uiisvn: Server sent unexpe

展开阅读全文
相关资源
正为您匹配相似的精品文档
相关搜索

最新文档


当前位置:首页 > 行业资料 > 其它行业文档

电脑版 |金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号