In the work, in order to improve the efficiency, we will use version control software to manage the project, such as SVN, Git and so on. Next take Svbversion as an example of the process of installing SVN and deploying projects in CentOS
Install the SVN server and use anonymous users to access and manage SVN projects
1. First install SVN server
Yum Install Subversion-y
2, set the repository directory, the default listening port number 3690
Svnserve-d-r/usr/svndata
3. Create SVN Project
Svnadmin Create/usr/svndata/gztest
4, test check out whether the project is successful, remember to modify iptables add 3690 port number to allow
Cd/var/www
SVN checkout svn://ip/gztest./
5. The test submission project is successful
Touch gztest.php
SVN commit.
When submitting an error: Connection refused by, on the internet to see a lot of said users do not have assigned permissions, I can test the anonymous user, everyone can check out and modify the code, and then view the configuration file vim/usr/svndata/gztest/conf/ Svnserve.conf Uncomment the following line:
Anon-access = Read #取消前面的分号注释并保证没有空格
And a new line is added below the row:
anon-access = Write
Note that there are no spaces in front of all the SVN configuration files, otherwise it will be an error, this is the SVN configuration file rules
6, after the completion of the modification to submit SVN, no error occurred
Second, SVN project management based on user rights assignment
1, modify the project configuration file vim/usr/svndata/gztest/conf/svnserve.conf, add the following content:
Anon-access = None #禁止匿名用户访问
auth-access = Write #验证用户具有写的权限
Password-db = passwd #保存用户名和密码的文件
Authz-db = Authz #用户权限认证的文件
Realm = Gztest #svn项目文件名字--Personal understanding
2. Edit the vim/usr/svndata/gztest/conf/passwd file to add a user:
MyTest = MyTest #等号左边是用户名右边是密码
3. Edit the Vim/usr/svndata/gztest/conf/authz file to add user groups and increase user Rights control:
Gztest = Gzinfo,gznew #左边是用户组, right is the user name contained in the user group
4. Set the user group to have read and write permissions to the Gztest project:
[gztest:/]
@gztest = RW #这里也可以对单独的用户设置读写权限
5. Check out Project Gztest using username in NetBeans,
Once checked out, the code for the project can be managed:
To this SVN installation and configuration introduction is complete, welcome to discuss together
CentOS Installation SVN