Collabnet Subversion server installation and configuration

Source: Internet
Author: User
Tags collabnet subversion server installation and configuration collabnet

Download Subversion

Http://subversion.tigris.org/servlets/ProjectDocumentList? Folderid = 91

In this example, select the svn-win32-1.4.6.zip version to download.

2. Double-click to install the subversion. Click Next during the installation process.

3. After the Subversion is installed, find httpd in the c: \ Program Files \ collabnet Subversion server \ httpd \ conf folder. open the conf file in a text editor and remove the following comments (delete the '#' Mark ):

# Loadmodule dav_fs_module modules/mod_dav_fs.so

# Loadmodule dav_module modules/mod_dav.so

Add the following two rows to the end of the loadmodule section.

Loadmodule dav_svn_module modules/mod_dav_svn.so

Loadmodule authz_svn_module modules/mod_authz_svn.so

After making the above modifications, we have completed the WebDAV work between SVN + Apache. Restart Apache. If the surface can be started normally, your work is successful. Let's go!

4. Create a version Library

(1) first, create a version library for the svn project. In this example, create the directory var/svnhome in the drive D. You can run the following command to create a version Library, if you need to create multiple version libraries, you only need to replace the names.

(2) [start]-> [run]-enter the [cmd] command to open the windows command window

(3) switch to the C: \ Program Files \ collabnet Subversion server \ httpd \ bin directory and run the following command:

> Cd c: \ Program Files \ collabnet Subversion server \ httpd \ bin

(4) create a version library. The command is as follows:

> Svnadmin create -- FS-type fsfs D:/var/svnhome/Projects

Press enter to wait for the prompt to be created. After the creation is complete, set the relevant password and permissions.

5. Add a User Password File

(1) enter the path c: \ Program Files \ collabnet Subversion server \ httpd \ bin in the CMD command window, and enter:

> Htpasswd-c d:/var/svnhome/projects/CONF/<FILENAME> <username>

The command for this instance is as follows:

> Htpasswd-c d:/var/svnhome/projects/CONF/passwordfile Admin

After the command is successfully executed, a password setting prompt is displayed, and the user's logon password can be set. Don't forget. It is used when you connect to the svn server.

[Note] In this example, the filename name uses passwordfile and the username uses admin (note that filename does not require a suffix ), in this way, you can create a passwordfile file named admin in the var/svnhome/projects/conf directory. This file will be used to configure permissions later.

(2) To add users later, run the following command:

> Htpasswd filename <username>

The command for this instance is as follows:

> Htpasswd D:/var/svnhome/projects/CONF/passwordfile wzh

For password settings, see the 5 (1) command.

(3) to delete a user, run the following command:

> Htpasswd-D filename <username>

 

[Note] If you do not want to encrypt the password, use the-CP parameter. MD5 encryption is used by default on Windows.

 

6. Set the permission File

(1) Use a text editor to generate a file named svnaccessfile in the var/svnhome/projects/conf path. The file will be named in C: \ Program Files \ collabnet Subversion server \ httpd \ conf is used in the configuration file. The extension is not used here. Edit the following content:

[Groups]

Committers = Admin

Developers = Allen

[/]

* = R

@ Developers = r

@ Committers = RW

[Projects:/]

@ Developers = RW

The basic meaning is that anyone in the root directory has read and write permissions, and the committers group has read and write permissions. The Admin has read and write permissions on projects, while the developers group has only read permissions.

Note: If you have a Chinese path, you need to save the file in utf8 format. It is not recommended to use a Chinese path, which is strictly prohibited in programming.

(2) append the username added in step 5 to the admin of the committers list.

Format: committers = admin, wzh

 

7. Configure the service

(1) edit the c: \ Program Files \ collabnet Subversion server \ httpd \ conf configuration file and add the followingCode.

 

<Location/SVN>

Dav SVN

Svnpath "D:/var/svnhome/Projects"

 

Authtype basic

Authname "Subversion repositories"

Authuserfile "D:/var/svnhome/projects/CONF/passwordflie"

Authzsvnaccessfile "D:/var/svnhome/projects/CONF/svnaccessfile"

 

Require valid-user

Svnautoversioning on

Modmimeusepathinfo on

</Location>

 

Note: If you use <location/SVN/>, you can list version Libraries under D:/var/svnhome/projects. If it is <location/SVN>, you cannot access HTTP: // 127.0.0.1/SVN project, which can only be accessed in this way, such as http: // 127.0.0.1/SVN/<projectname>

 

(2) setting explanation

<Location> the URL of the Subversion library is http: // IPaddress/SVN/

Dav SVN tells apache which module responds to the request of that URL-this is the Subversion module.

Svnpath tells subversion that the version library to be viewed is under D:/var/svnhome/projects.

Authtype basic activates the basic authentication, that is, the user name/password.

Authname is used to indicate the information in the pop-up dialog box that requires entering authentication information. You can use Chinese characters.

Authuserfile specifies the file using the authentication Password

Authzsvnaccessfile: path file of the access control permission of the Subversion Library

Require valid-User specifies that only users with the correct user/password can access the URL

 

8. Install SVN for testing.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.