Subversion, otherwise known as SVN, is an open source version control system used to store historical changes of your project files such as documentation, coding etc.
This article helps you to install svn on ubuntu 12.04 . also see the SVN installation on centos 6 Install svn server on centos 6 Subversion (SVN):
Easy version control for Linux. RabbitVCS is a set of graphical tools written to provide simple and straightforward access to the version control systems you use. RabbitVCS provide multiple clients and extensions designed to give you a uniform experience no matter what development tools you use. RabbitVCS installation on centos 6.4.
Install svn on ubuntu 12.04.
» Install and configure Apache2
» Install and configure SVN » Testing Before installing SVN, you have to install and configure Apache webserver. Press ALT + CTR + T to open terminal. Install and configure Apache Step 1 » Issue the below command to install apache2. krizna@leela:~$ sudo apt-get install apache2 Step 2 » After installation open this file /etc/apache2/httpd.conf and add the below line to avoid warning during apache service restart . ServerName localhost Step 3 » Restart apache service . krizna@leela:~$ sudo /etc/init.d/apache2 restart Step 4 » Open http://ipaddress in your browser ( Eg: http://10.0.2.15 ) , you will get the page like below . Install and configure SVN. Step 5 » Now start installing SVN server. Type the below command to install SVN packages. krizna@leela:~$ sudo apt-get install subversion libapache2-svn Step 6 » After installation, plan as per your needs and start creating repositories.In my case i’m creating folder structure like /svn/repositoryname . krizna@leela:~$ sudo mkdir /svn Step 7 » create a repository test using the below command. krizna@leela:~$ sudo svnadmin create /svn/test Step 8 » Modify the permissions for the repository. krizna@leela:~$ sudo chown -R www-data:www-data /svn/test Step 9 » Create a file to store user authentication details (/etc/subversion/reponame.users). krizna@leela:~$ sudo htpasswd -c /etc/subversion/test.users krizna Here test.users is the filename and krizna is the username for accessing repository. you must omit -c to add additional users.
Step 10 » Create /etc/apache2/conf.d/svn.conf file and add the below lines.
Step 11 » Now restart apache service.
krizna@leela:~$ sudo /etc/init.d/apache2 restart You have successfully installed and configured SVN server on ubuntu 12.04.Testing Step 12 » For a quick testing , you can access http://yourip/repos/reponame in your browser ( Eg http://10.0.2.15/repos/test ) and you can see the page like below after successful authentication. Step 13 » You can test checkout and commit using command line . create a folder to checkout krizna@leela:~$ mkdir svntest checkout new copy to svntest folder using the below command. krizna@leela:~$ svn co http://[email protected]/repos/test svntest/ create some files. krizna@leela:~$ cd svntest/ add the files before commit. krizna@leela:~/svntest$ svn add test1.txt test2.txt now commit the added files . you can add log message and close the editor. krizna@leela:~/svntest$ svn commit Now open your repository in the browser , you can see the committed files. You can use svn clients such as Tortoisesvn for windows and Rapidsvn for ubuntu. good luck
SVN (Subversion) is an opensource version control system. it is used to store previous changes of your project files like documentation, coding etc. also you can track and identify who made the particular changes in the project files . Here in this article we can see how to setup SVN server on ubuntu 14.04 .
Setup SVN server on ubuntu 14.04
Let’s start the installation .
Step 1 » Issue the below command to update the repositories. sudo apt-get update Step 2 » After updating repositories , Issue the below command to install SVN and apache webserver (To access SVN through http ) . sudo apt-get install subversion apache2 libapache2-svn apache2-utils Step 3 » Now create a directory and create a new repository in that directory ( Here i’m using testrepo as repository name ). sudo mkdir -p /svn/repos/ Step 4 » Now change ownership for the repository. sudo chown -R www-data:www-data /svn/repos/testrepo Step 5 » Create a file testrepo.conf in /etc/apache2/sites-available/ and add the below lines for creating apache virtual host.
SVNParentPath /svn/repos/ : Parent Directory without repository name.
AuthUserFile /etc/svnpasswd : File need to be created ( Step 8) for user details.
Step 6 » Issue the below command to enable the Site ( testrepo in the below command should match the file name created in the previous step ) sudo a2ensite testrepo Step 7 » Now restart or reload apache service. sudo service apache2 reload Step 8 » Issue the command to create user for accessing repository and add the user details to /etc/svnpasswd file. Use this command to create first user. sudo htpasswd -cm /etc/svnpasswd user1 Use the same command without c option to create additional users. sudo htpasswd -m /etc/svnpasswd user2 Step 9 » Now you can access http://yourip/svn/testrepo in your browser ( Eg http://10.0.1.15/svn/testrepo ) and you can see the page like below after successful authentication. That’t it , your server is ready. You could use svn clients such as Tortoisesvn on windows and Rapidsvn on ubuntu for commiting and updating repository. good luck Comments are closed.
|
AuthorWrite something about yourself. No need to be fancy, just an overview. Archives
December 2022
Categories |