Environment Description: ttuserver12.04/svn1.6/apache21. First, create the svn group and user: addgroudsvnuseraddsvn-gsvn-m // Add the svn username,-g and create the svn group in which it belongs, -m simultaneously create the home Directory of the svn user passwdsvn // set the svn user's password 2. Install apach
Environment Description: Ubuntu Server 12.04/svn1.6/apache2
1. Create an svn group and user first:
Addgroud svn
Useradd svn-g svn-m // Add the svn username,-g and specify the svn group in which it is located.-m also creates the home directory where the svn user is located.
Passwd svn // set the svn User Password
2. Install apache2 and svn server
Sudo apt-get install apache2
Sudo apt-get install subversion
Sudo apt-get install libapache2-svn
After the above installation, you can directly access the apache homepage, such as http: // localhost/
3. Create an svn version Library
Sudo mkdir/var/svn
Sudo svnadmin create/var/svn/repos
You can view all the folders and configuration files of the svn version library in the/var/svn/repos directory, such as conf?db=format=hooks=locks=readme.txt.
4. Configure and import the project
Sudo mkdir/opt/idbtest
Sudo mkdir/opt/idbtest/branches
Sudo mkdir/opt/idbtest/tags
Sudo mkdir/opt/idbtest/trunk
Import the project to the version Library: svn import/opt/idbtest file: /// var/svn/repos/idbtest-m "initial import" // opt/idbtest indicates the project to be introduced. file: /// var/svn/repos/idbtest indicates the version library of svn, Which is initialized and introduced here.
5. Configure svn to apache for http web access
Sudo vi/etc/apache2/apache. conf, paste the following file to the end of apache. conf, as follows:
DAV svn
SVNPath/var/svn/repos
AuthType Basic
AuthName "Subversion Repository"
AuthUserFile/var/svn/repos/conf/passwd
Require valid-user
Note: This configuration file tells apache that the svn access path is related to the configuration file. Restart the apache server, and then you can remotely access the server through http: // localhost/svn.
Restart apache server:/etc/init. d/apache2 restart
Of course, you need to verify the login user. Next we will introduce how to add svn users.