#!/bin/bash #Download SVN yum -y install subversion #Alibaba Cloud oss data wget -P /root https://babyrita.oss-cn-beijing.aliyuncs.com/lnmp/quyeweb/ziliao.zip #Unzip the data file unzip ziliao.zip #Create a new svndata directory mkdir /home/svndata #The SVN server listens to the default port 3690 svnserve -d -r /home/svndata #Create SVN repository svnadmin create /home/svndata/www #Copy the data to the corresponding location\cp /root/ziliao/passwd.txt /home/svndata/www/conf/passwd \cp /root/ziliao/svnserve.txt /home/svndata/www/conf/svnserve.conf \cp /root/ziliao/post-commit.txt /home/svndata/www/hooks/post-commit #Hook file executable chmod +x /home/svndata/www/hooks/post-commit cd /home/svndata/www/ #Check out SVN to local and website root directory ---Automation --No need to enter password SVN co svn://127.0.0.1/www --username svn1113 --password svn123 --no-auth-cache svn co svn://127.0.0.1/www /home/wwwroot/www --username svn1113 --password svn123 --no-auth-cache #Create users and user groups groupadd www useradd -g www www #Set the permissions of the website directory chown -R www:www /home/wwwroot/www Knowledge point supplement: Let's take a look at the Linux shell script SVN automatically update the project and package, publish, and backup Here we prepare a configuration file to save the SVN address, destination path, username and password. Configuration file name: toolConfig.properties #svn address svnAddress=https://192.168.1.253/[yourPath] #Local path (destination address) localDir=E:\shelltest #svn username userName=jack #svn password password=123456 Corresponding shell script #!/bin/bash source ./toolConfig.properties svn_ip=${svnAddress} local_path=${localDir} u_name=${userName} p_wd=${password} svn co ${svn_ip} ${local_path} --username ${u_name} --password ${p_wd} Summarize The above is the details of how to install shell scripts in Svn with one click under linxu. For more information about installing shell scripts in Linux with one click, please pay attention to other related articles on 123WORDPRESS.COM! You may also be interested in:
|
<<: Implementation of React page turner (including front and back ends)
>>: Vue.js implements simple timer function
This article shares the specific code of JavaScri...
Table of contents Nginx load balancing configurat...
I've been learning Docker recently, and I oft...
There is no doubt that containers have become an ...
Preface When using Docker in a production environ...
First: Copy code The code is as follows: <input...
1. Deploy nginx service in container The centos:7...
Table of contents 1. What is a directive? Some co...
1. This is a bit complicated to understand, I hop...
Preface Recently, a data was operated incorrectly...
Insert data into mysql database. Previously commo...
Table of contents Main issues solved 1. The data ...
<br />The solution steps are as follows: Sta...
Table of contents 1. Baidu Map API Access 2. Usin...
When I was studying CSS recently, I found that I ...