Build and simple configuration and use of SVN server under Linux (CentOS)

Source: Internet
Author: User
Tags svn collabnet



The build of the Subversion (SVN server) under Linux:

1. Install Subversion


#查看本机是否已安装subversion


[Email protected] etc]# Rpm-qa Subversion


[Email protected] etc]#


#卸载旧版


[email protected] etc]# Yum Remove subversion


#安装SVN to install additional services at the same time for future operations, you can install only SVN


[email protected] etc]# Yum install httpd httpd-devel Subversion mod_dav_svn mod_auth_mysql


Confirm that the SVN module is installed


To verify the installation:


[Email protected] conf]# Svnserve--version


Svnserve, Version 1.6.11 (r934486)


Compiled at APR 11 2013,16:13:51


Copyright (C) 2000-2009 CollabNet.


Subversion is an open source software, see the http://subversion.tigris.org/site.


This product contains software developed by CollabNet (http://www.Collab.Net/).


The following repository back-end (FS) modules are available:


* Fs_base: The module can only operate the BDB repository.


* FS_FS: The module works with a text file (FSFS) repository.


Cyrus SASL certification is available.


2. Create a code base


[Email protected] etc]# mkdir-p/opt/svn/repositories


[Email protected] etc]# svnadmin create/opt/svn/repositories


After executing the above command, the repositories library is automatically established to view the/opt/svn/repositories

Folder discovery contains Conf, db,format,hooks, locks, README.txt and other files, stating that an SVN repository has been established.


Subversion Directory Description:
*DB Directory: All version-controlled data storage files
*hooks directory: The directory where the hook script files are placed
*locks directory: Used to place subversion to see the hard lock data of the directory, used to track access to the vault client
*format file: is a text file with only an integer in it. Represents the version number of the current vault configuration
*conf directory: Is the configuration file of this warehouse (user access account, permissions, etc.) of the warehouse


3. Add Users


To add SVN users is very simple, just add a "Username=password" entry in the/opt/svn/repositories/conf/passwd file. For testing, I added the following:


[Users]
# Harry = Harryssecret
# sally = Sallyssecret
PM = PM_PW
Server_group = SERVER_PW
Client_group = CLIENT_PW
Test_group = TEST_PW


4, User Rights control


In the/opt/svn/repositories/conf/authz file


[Groups]


Create a permission group here and specify the user in the group, intermediate, split

# harry_and_sally = harry,sally
# Harry_sally_and_joe = Harry,sally,&joe
admin = Zhangcy,liuzz,shenkun
user = Yangxt,maym,lizh,dongyan

Assigning Permissions to permission groups
[/]
@admin = RW
@user = RW
* =


R indicates that the directory has Read permissions, W indicates that the directory has write permissions, and RW indicates that the directory has read and write permissions.

The last line of * = indicates that no one else is allowed to access this directory except for the user group with the permissions set above. This is very important, be sure to add!

5, modify the svnserve.conf file, let the user and policy configuration to the efficiency.


[General]
Anon-access = None
auth-access = Write
Password-db =/opt/svn/repositories/conf/passwd
Authz-db =/opt/svn/repositories/conf/authz


6. Start SVN server

Svnserve-d-r/opt/svn/repositories/or specify a port number to start the server svnserve-d-r/opt/svn/repos--listen-port 3391


SVN default Listener 3690 Port


The resources are as follows
Http://jingyan.baidu.com/article/d45ad148e9cfc069542b8046.html


Http://www.ha97.com/4467.html



7. Installation of SVN plugin in MyEclipse


Download MyEclipse under SVN plugin (Zip package): http://subclipse.tigris.org/servlets/ProjectDocumentList?folderID=2240


Create a new SVN folder under the MyEclipse installation directory Dropins and move the downloaded zip package to the extracted features and plugins folder to SVN, then restart MyEclipse.


After rebooting, find SVN in MyEclipse Window show View Other and display the SVN repository and link the server in the repository.


Reference: http://www.cnblogs.com/xdp-gacl/p/3497016.html


8. New Project for SVN


Under MyEclipse, create or select a project to be versioned with SVN, right-click Project under Team Share project, and follow the prompts to release the item to SVN for version control.


9. Use of SVN plugin in MyEclipse: http://blog.sina.com.cn/s/blog_8a3d83320100zhmp.html

Build and simple configuration and use of SVN server under Linux (CentOS)

Related Article

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.