Subversion Apache setting


tools download:

  1. apache_2.0.63-win32-x86-no_ssl.msi
    address:http://apache.mirror.phpchina.com/httpd/binaries/win32/apache_2.0.63-win32-x86-no_ssl.msi
  2. svn-1.4.5-setup.exe
    address:http://subversion.tigris.org/files/documents/15/39559/svn-1.4.5-setup.exe
  3. TortoiseSVN. Use it to control the subversion tools.

 

Setup the software

  1. setup Apache. When it is installed completely. Use the browser and add the addresshttp://localhost  to check.
  2. setup svn-1.4.5-setup.exe. When the setup is finished. Open the cmd and add svn --version to check it is working or not.

 

config the svn

 

  1. create the file in the hard disk. E:\svnroot\MyProject .And then use svnadmin create E:\svnroot\MyProject command to create relative config file and folder . If it can do ,you can see there are many files and folders  which are created in the MyProject folder.
  2. open conf folder, and then open svnserve.conf file, find out the bottom line # password-db = passwd. And remove the remark #,it means if you want to enter MyProject file ,you need password.However, where to set our passwords. step 3
  3. open the anther file in the conf folder which is called passwd,and then use the text editor to add the following sentences.
    写道
    [users]
    hadeslee=hadeslee1234
    tom=123456
     
    The above sentences mean that we created two users.one is hadeslee, password hadeslee1234 .And the other is tom ,password is 123456.
  4. create the file called access.auth . And add the following sentences:
    access.auth 写道
    [MyProject:/]
    hadeslee = rw
    [MyProject:/module1]
    tom=rw
    hadeslee=rw
     
    The above sentences mean that hadeslee has the read and write authority to control the MyProject and module1 folders.But tom only has the read and write to control the module1 folder.

 

Config the apache

  1. Enter Subversion home folder,find the follow two files in the bin folder.
    mod_authz_svn.so
    mod_dav_svn.so
     
    copy these two files to the Apache home's modules folder.
  2. open Apache home's conf folder ,open httpd.conf file and add the following sentences:
    httpd.cof 写道
    LoadModule dav_svn_module modules/mod_dav_svn.so
    LoadModule authz_svn_module modules/mod_authz_svn.so
     
    and then remove the mark # before
    httpd.conf 写道
    LoadModule dav_module modules/mod_dav.so
     
  3. open the httpd.conf file in the config folder,add the following consent:
    httpd.conf写道
    <Location /svn/MyProject>

    DAV svn
    SVNPath E:/svnroot/MyProject

    AuthzSVNAccessFile E:/svnroot/MyProject/conf/access.auth
    Satisfy Any
    Require valid-user

    AuthType Basic
    AuthName "Subversion repositories"
    AuthUserFile E:/svnroot/MyProject/conf/users.auth
    Require valid-user
    </Location>
     
  4. generate users.auth file .Enter the apache home's bin folder, input the following commands:
    D:\Program Files\Apache Group\Apache2\bin>
    htpasswd -cb users.auth hadeslee hadeslee1234
    
    
    
    Automatically using MD5 format.
    Adding password for user hadeslee

    D:\Program Files\Apache Group\Apache2\bin>
    if you want to  add another use ,use the following commands :
    D:\Program Files\Apache Group\Apache2\bin>
    htpasswd -b users.auth tom 123456 
    Automatically using MD5 format.
    Adding password for user tom

    D:\Program Files\Apache Group\Apache2\bin>
    tip: c means to recreate the users.auth.
    copy the users.auth to E:/svnroot/MyProject/conf/

Total, all is finished . open the browser and input the http://localhost/svn/MyProject address to check

If you want to add other project in the subversion server.There are several suggestions:

  1. put the project in the MyProject folder ,you don't need to add any other setting .
  2. If you  want to create the other folder ,such as YourProject .You can add <Location...>setting into httpd.conf file.Of course ,you should also recreate the password.

eclipse config

add the eclipse plugin
address:
http://subclipse.tigris.org/update_1.4.x/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值