Install Svn server using Subversion Edge in CentOS7

SVN refers to Subversion, an open source version control system. It allows multiple people to work together on the same project and track changes in file versions. Through SVN, users can record and manage historical modifications of the project, and can also easily go back to previous versions. SVN provides command line tools and graphical interfaces for version control operations, and is widely used in fields such as software development, team collaboration, and version management.

1. Environmental preparation

The operation of Subversion Edge requires a java environment, so jdk must be installed. And set the JAVA_HOME environment variable.

1. Download the jdk installation package and unzip it

wget https://download.oracle.com/otn/java/jdk/8u371-b11/ce59cff5c23f4e2eaf4e778a117d4c5b/jdk-8u371-linux-x64.tar.gz

tar zxvf jdk-8u371-linux-x64.tar.gz

2. Move to the /usr/local/ directory and rename it to jdk

mv jdk-8u371/ /usr/local/jdk1.8

3. Configure environment variables, vim /etc/profile file, and add the following content at the end

JAVA_HOME=/usr/local/jdk1.8
PATH=${JAVA_HOME}/bin:$PATH

4. Execute the command to make it effective

source /etc/profile

5. Check whether the java version is correct

 

2. Download and install svn

1. The downloaded version is 5.2.0

#下载CollabNetSubversionEdge-5.2.0版本压缩包
wget https://downloads-guests.open.collab.net/files/documents/61/17071/CollabNetSubversionEdge-5.2.0_linux-x86_64.tar.gz

#解压CollabNetSubversionEdge-5.2.0_linux-x86_64.tar.gz
tar zxvf CollabNetSubversionEdge-5.2.0_linux-x86_64.tar.gz

#移动到/usr/local/目录下
mv csvn /usr/local/

2. Create the svn user and set the owner permissions of the csvn directory to the svn user.

#创建svn用户
[root@localhost ~]# useradd svn

#给csvn目录赋权
[root@localhost ~]# chown -R svn:svn /usr/local/csvn

The execution content is as shown below:

3. Edit the svn configuration file

1. Switch to the svn user (do not use root to start, because root permissions are too large, and permission problems may occur during subsequent use)

[root@localhost conf]# su - svn

[svn@localhost ~]$ cp /usr/local/csvn/data/conf/csvn.conf.dist /usr/local/csvn/data/conf/csvn.conf

[svn@localhost conf]$ vim /usr/local/csvn/data/conf/csvn.conf

 Exit after saving, and then start csvn:

[svn@localhost csvn]$ bin/csvn start
Starting CSVN Console...
...
CSVN Console started
Waiting for application to initialize (this may take a minute).......................................
CSVN Console is ready at http://localhost:3343/csvn

It can be seen from the echo that the csvn service has been started normally. Enter IP: 3343/csvn in the browser to enter the web page (the username and password are both admin)

The web running interface is

 

 At this point, the installation and deployment of the Svn server using Subversion Edge in CentOS7 is completed.

Guess you like

Origin blog.csdn.net/qq_54494363/article/details/131250901