Sunday, July 15, 2012

Subversion


Install Subversion that is the software for version control.

For this example, Use Subversion with WebDAV function, so httpd is required and SSL settings is also done.
[1] Install and Configure Subversion.
[root@www ~]#
yum -y install subversion mod_dav_svn
[root@www ~]#
vi /etc/httpd/conf.d/subversion.conf
# line 26-39: uncomment and change like follows


   DAV svn
   SVNParentPath /var/www/svn
# # Limit write permission to list of valid users.
  
      # Require SSL connection for password protection.
      SSLRequireSSL
      AuthType Basic
      AuthName "Authorization Realm"
      AuthUserFile
/etc/httpd/conf/.htpasswd

   
# specify access control file

     
AuthzSVNAccessFile /etc/svnusers

      Require valid-user
  
[root@www ~]#
vi /etc/svnusers
# set access right like an example below

[site:/]
# all users are writable

* = rw
# cent is writable

[site:/directory]
cent = rw
# userB is readable

userB = r
# userC is not permitted

userC =
[root@www ~]#
mkdir -p /var/www/svn/site

[root@www ~]#
svnadmin create /var/www/svn/site
 
# create a repository

[root@www ~]#
chown -R apache. /var/www/svn

[root@www ~]#
htpasswd -c /etc/httpd/conf/.htpasswd cent
 
# add a user

New password:
# set password

Re-type new password:
Adding password for user cent
[root@www ~]#
/etc/rc.d/init.d/httpd restart

Stopping httpd:
[ OK ]

Starting httpd:
[ OK ]

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home