Chinaunix首页 | 论坛 | 博客
  • 博客访问: 58178
  • 博文数量: 27
  • 博客积分: 2040
  • 博客等级: 大尉
  • 技术积分: 265
  • 用 户 组: 普通用户
  • 注册时间: 2009-01-03 17:21
文章分类
文章存档

2010年(14)

2009年(13)

我的朋友

分类: LINUX

2010-05-09 16:47:05

1, 安装程序包 yum install httpd subversion mod_dav_svn
2, 在启动httpd服务后,发现不能通过浏览器访问,一般以由于防火墙的原因,尝试 /etc/init.d/iptables stop 即可
3, 创建 subversion 仓库 svnadmin create /opt/subversion/repositories/svnveb
4, 使用 htpasswd 创建 subversion 访问帐户
            htpasswd -c /opt/subversion/repositories/user.password username
5, 创建 subversion 访问策略文件 /opt/subversion/access.policy
6, 配置 /etc/httpd/conf.d/subversion.conf 文件如下:

LoadModule dav_svn_module     modules/mod_dav_svn.so
LoadModule authz_svn_module   modules/mod_authz_svn.so

#
# Example configuration to enable HTTP access for a directory
# containing Subversion repositories, "/var/www/svn".  Each repository
# must be readable and writable by the 'apache' user.  Note that if
# SELinux is enabled, the repositories must be labelled with a context
# which httpd can write to; this will happen by default for
# directories created in /var/www.  Use "restorecon -R /var/www/svn"
# to label the repositories if upgrading from a previous release.
#

#
# To create a new repository "" using
# this configuration, run as root:
#
#   # cd /var/www/svn
#   # svnadmin create stuff
#   # chown -R apache.apache stuff
#

   DAV svn
   SVNParentPath /opt/subversion/repositories

#   # Limit write permission to list of valid users.
#  
#      # Require SSL connection for password protection.
#      # SSLRequireSSL
#
      AuthType Basic
      AuthName "Subversion Repositories"
      AuthUserFile /opt/subversion/user.password
      AuthzSVNAccessFile /opt/subversion/access.policy
      Satisfy Any
      Require valid-user
#  

7, 重启 httpd 服务


阅读(738) | 评论(0) | 转发(0) |
0

上一篇:世博小记

下一篇:JavaScript 程序收集

给主人留下些什么吧!~~