centos7 Next svn Installation and configuration

 

1. Environmental Science

centos7

2. install svn
yum -y install subversion

3. To configure

Set up a version Library Directory
mkdir /www/svndata

svnserve -d -r /www/svndata

4. Build version Library

Create a new Subversion project
svnadmin create /www/svndata/oplinux

Configuration allows users to rsync visit
cd /www/svndata/oplinux/conf

vi svnserve.conf
anon-access=read
auth-access=write
password-db=passwd

notes : The modified file cannot be preceded by spaces , Otherwise start svn server error

vi auth

[groups]

# harry_and_sally = harry,sally

manager = sally

# [repository:/baz/fuz]
# @harry_and_sally = rw
# * = r
[/]
@manager=rw
*=r

vi passwd
[users]
#< user 1> = < password 1>
#< user 2> = < password 2>
sally=123456

5.svn Service port 3690 Let go of it , Otherwise you won't be able to access ;

Please check the following items in turn
a, Is the server running , Has the corresponding port been opened
If the server is svnserve, Check to see if it's running svnserve, Have you opened 3690 port
Check can be run on the server netstat -an See if the corresponding port is LISTEN 
b, Does the firewall open the corresponding port
c, Whether the client can connect to the corresponding port of the server
Use command telnet The server IP Corresponding port
Such as :telnet 192.168.0.1 3690

If it doesn't open ,centos7 By default firewall To replace the iptables , The following operations are required .

Edit profile

vi /etc/sysconfig/iptables # Edit firewall profile

Add the port number you need after the following

-A INPUT -m state --state NEW -m tcp -p tcp --dport 22 -j ACCEPT# Default on 22 Of sshd port

-A INPUT -m state --state NEW -m tcp -p tcp --dport The port number you need  -j ACCEPT

Save after exit

systemctl restart iptables.service # Finally restart the firewall to make the configuration effective

Can solve

6. Client connection

svn co svn://ip/oplinux
User name, password :123456

===============================================================

6. Realization SVN And WEB Sync , Sure CO One came out , It can also be directly distributed in the warehouse

1) Set up WEB The server root directory is /www/webroot

2)checkout One copy SVN

svn co svn://localhost/oplinux /www/webroot

Modify the authority to WEB user

chown -R apache:apache /www/webroot/oplinux

3) Set up synchronization scripts

cd /www/svndata/oplinux/hooks/

cp post-commit.tmpl post-commit

edit post-commit, Add the following at the end of the file

export LANG=en_US.UTF-8
SVN=/usr/bin/svn
WEB=/www/webroot/
$SVN update $WEB –username rsync –password rsync
chown -R apache:apache $WEB

Increase script execution permissions

chmod +x post-commit

from :https://www.cnblogs.com/zhouqingda/p/6002169.html

centos7 svn More articles about the construction of the server

  1. linux(centos7) Next SVN How to build a server

    linux(centos) Next SVN How to build a server ? Speaking of SVN The server , I'm sure you all know that , It can be in LINUX How to build SVN What about servers? ? So let's share with you today linux(centos) build SVN The idea of the server ! ...

  2. centos7 Next SVN How to build a server

    Centos7 build svn The server linux(centos) Next SVN How to build a server ? Speaking of SVN The server , I'm sure you all know that , It can be in LINUX How to build SVN What about servers? ? So let's share with you today linux(ce ...

  3. centos7 svn Server setup

    System environment :centos 7.5 yum install svn yum install subversion -y establish svn Version Library Directory mkdir -p /var/svn/svnrepos Create a version in the version Library Directory ...

  4. SVN Server local build and use

    Reprint please indicate the original address :http://www.cnblogs.com/ygj0930/p/6623026.html  Use SVN Code management , We need to build a server resource library , And then use SVN The computer installation of SVN The client or ...

  5. svn Server build backup and restore and svnmanager Use

    svn Server build backup and restore and svnmanager Use One .svn Installation and configuration of server software 1. install svn Version Library Software # yum install -y subversion 2. establish svn Version library data storage ...

  6. Ubuntu SVN The construction and configuration of the server ( turn )

    Ubuntu SVN The construction and configuration of the server One .         install sudo apt-get install subversion sudo apt-get install libapache2-sv ...

  7. svn The construction of the server and the use of the client

    1.svn The construction of the server and the use of the client , See blog below for installation https://blog.csdn.net/zh123456zh789/article/details/80921179 explain : The server just uses ...

  8. Windows Next SVN Server building steps

    1. download svn Server and client Server side VISUALSVN SERVER:https://www.visualsvn.com/ client TortoiseSVN:https://tortoisesvn.net ...

  9. SVN The construction and use of the server

    VisualSVN Server and TortoiseSVN The download , install , Sinicization :SVN Server setup and use ( One ) How to use VisualSVN Server Build version Library , as well as TortoiseSVN Use :SVN clothing ...

Random recommendation

  1. Module Zero User management

    return <Module Zero Study Directory > User entity User manager User authentication User entity The user entity represents a user of the application , It derives from AbpUser class , As shown below : public class User : ...

  2. Set and Map

    Set and Map

  3. centos 5.8 64 Bit system installation mysql5.6

    mysql5.5 The above version requires cmake         1 . install cmake wget http://www.cmake.org/files/v2.8/cmake-2.8.10.2.tar.g ...

  4. mac for gdb Create a certificate to enable it to debug other applications

    1 Use /Applications/Utilities/Keychain Access.app Create certificate Keychain access -> Certificate assistant -> Create certificate Give the certificate essay a name , Identity type " Self signed ...

  5. vue2

    props Passing data to subcomponents is often used , It's usually defined in sub components props To accept the data , When the parent component changes the data, the data of the child component is also updated . But there's a hole here , Look at the code first : <pagination :pa ...

  6. HTTP Chapter one

    Why learn HTTP? Most of us Web Applications are based on HTTP To develop . We are right. Web All operations are passed HTTP Protocol to transmit data . HTTP The main purpose of this paper is to make documents related to each other , Forming hypertext can interact with each other ...

  7. [Swift]LeetCode525. A continuous array | Contiguous Array

    Given a binary array, find the maximum length of a contiguous subarray with equal number of 0 and 1. ...

  8. C++ Programming method 3: Array subscript operator overload

    Array subscript operator overload Function declaration form Return type operator[]( Parameters ): If the return type is a reference , Then the array operator call can appear on the left side of the equation , Accept the assignment , namely : Obj[index] = value; If the return type ...

  9. Python Parser

    When we write Python Code , What we get is a Python Code to .py Text file with extension . To run code , Need Python Interpreter to execute .py file . Because of the whole Python Language is open source from specification to interpreter ...

  10. use Java Batch rename files

    In advance C Create... On disk “ Photo ” and “ Photo 1” Two folders 1import java.io.*; public class Jack { public static void main(String[] arg ...