SVN+http(RPM安装版)

一、安装包

 

yum install subversion apr apr-util   mod_dav_svn  httpd

 


 

二、配置SVN

 mkdir -p/svn/VER

svnadmin create /svn/VER


查看目录下面是不是有文件,然后进行配置

 

1、 vi svnserve.conf

anon-access = none

auth-access = write

password-db = passwd

authz-db = authz

realm = VER

 

 2、vi authz

#[/]

#@admin = rw

 

[VER:/]

@manager = rw

* =

 

 3、vi passwd

[users]

# harry =harryssecret

# sally =sallyssecret

admin      = admin


启动SVN

 svnserve -d -r /svn/


三、配置httpd

 vi /etc/httpd/conf.d/subversion.conf

<Location/svn>

   DAV svn

   SVNPath /svn/VER

   # Limit write permission to list of validusers.

#   <LimitExcept GET PROPFIND OPTIONSREPORT>

      # Require SSL connection for passwordprotection.

      # SSLRequireSSL

      AuthType Basic

      AuthName "Authorization Realm"

      AuthUserFile /etc/httpd/conf.d/passwd

      Require valid-user

#   </LimitExcept>

</Location>

 

 

chown-R apache.apache/svn/VER

 

查看是不是有相应模块

 ls/etc/httpd/modules/ | grep svn

mod_authz_svn.so

mod_dav_svn.so

 

httpd加用户

 htpasswd-cm passwd admin

 

 

 

 

三、测试

 

svn co http://192.168.1.135/svn



你可能感兴趣的:(linux,SVN,rpm)