| 
	Apache 下SVN项目管理使用说明 
	(1)Apaceh和SVN先要装好。 
	(2)在apache的目录下找到httpd.conf文件,在最后一行增加如下配置Include conf/svn.properties
 
	(3)在apache的目录conf下增加一个svn.properties文件增加内容如下(1):
 
	  DAV svnSVNParentPath "D:/svn"
 AuthType Basic
 AuthName "Subversion repositories"
 AuthUserFile "D:/svn/apache-conf/passwd.txt"
 AuthzSVNAccessFile "D:/svn/apache-conf/authz.txt"
 Require valid-user
 
	(4)创建文件夹
 D:/svn    根目录
 D:/svn/apache-conf/passwd.txt 存放用户和密码
 D:/svn/apache-conf/authz.txt 存放权限
 
	(5)创建用户和密码到指定文件中建入apache的目录下
 D:\Program Files (x86)\Apache Software Foundation\Apache2.2\bin>htpasswd D:/svn/
 apache-conf/passwd.txt admin
 New password: *****
 Re-type new password: *****
 Adding password for user admin
 
	注:如果第一次创建要加 -c 
	(6)查看D:/svn/apache-conf/passwd.txt文件test_a:$apr1$OjRiZrcQ$Ak35e8BFBID8yoGTPbJMw1
 test_b:$apr1$VFlQ9DGr$k8Y9cOQOPZZH6gO4Moubm1
 test_c:test_c
 admin:$apr1$3kGI5K9V$eiprg8yv8Xsr2uqUERb8x.
 
	注:也可以加明文密码 
	(7)创建svn仓库目录D:\Program Files (x86)\Subversion\bin>svnadmin create D:\svn\lmsj
 
	(8)增加权限内容D:/svn/apache-conf/authz.txt,内容如下
 [groups]
 admin=admin
 other_1=test_a
 other_2=test_b,test_c
 
	[pro_1:/]@admin=rw
 
	[pro_1:/test]@other_1=rw
 
	[pro_1:/test2]@other_2=rw
 
	-----------------例 创建一个lmsj的目录----------------
 (1)创建目录和文件
 D:\app_svn\conf\authz.txt
 D:\app_svn\conf\passwd.txt
 
	(2)配置svn.properties文件,路径上面有 
	  DAV svnSVNParentPath "D:/app_svn"
 AuthType Basic
 AuthName "Subversion repositories"
 AuthUserFile "D:/app_svn/conf/passwd.txt"
 AuthzSVNAccessFile "D:/app_svn/conf/authz.txt"
 Require valid-user
 
	(3)创建用户在D:/app_svn/conf/passwd.txt文件中
 D:\Program Files (x86)\Apache Software Foundation\Apache2.2\bin>htpasswd D:/app_
 svn/conf/passwd.txt admin
 New password: *****
 Re-type new password: *****
 Adding password for user admin
 
	注,以上创建的用户是加密的密码,也可以手工直接增加用户,可以是明文密码admin:$apr1$3kGI5K9V$eiprg8yv8Xsr2uqUERb8x.
 test_a:test_a
 
	(4)增加权限,修改D:/app_svn/conf/authz.txt文件,内容如下[groups]
 admin=admin
 other=test_a
 
	[/]@admin=rw
 
	[lmsj:/]@admin=rw
 @other=r
 
	(5)增加仓库,在svn安装目录的bin下D:\Program Files (x86)\Subversion\bin>svnadmin create D:\app_svn\lmsj
 
	(6)重启apache 
	(7)SVN客户端测试http://localhost/app_svn/lmsj
 
	(责任编辑:IT)
 |