Useful Snippets

Welcome!


This blog is used to collect useful snippets related to Linux, PHP, MySQL and more. Feel free to post comments with improvements or questions!

RSS Latest posts from my personal blog


Most viewed posts


Subscribe to RSS feed


Setting up an SVN server with Apache and mod_dav_svn on CentOS 6

Stanislav KhromovStanislav Khromov

Perfect tutorial for setting up an SVN repository in a matter of minutes: Install SVN (Subversion) Server on Fedora 18/17, CentOS/Red Hat (RHEL) 6.4/5.9

The only change I do is putting the Location block in a Virtualhost. That way it will only match the path on the VirtualHost domain and not the entire server. (With the vanilla tutorial, if you run multiple virtualhosts, all of those would return the SVN repo on the /svn path, which is not ideal because it essentially becomes an unusable url on every site.)

Example:

<VirtualHost *:80>
ServerName      my-domain.com
DocumentRoot    "/var/www/html/my-domain.com"

<Location /svn>
   DAV svn
   SVNParentPath /var/www/svn
   AuthType Basic
   AuthName "Subversion repositories"
   AuthUserFile /etc/svn-auth-users
   Require valid-user
</Location>

</VirtualHost>

Web Developer at Aftonbladet (Schibsted Media Group)
Any opinions on this blog are my own and do not reflect the views of my employer.
LinkedIn
Twitter
WordPress.org Profile
Visit my other blog

Comments 0
There are currently no comments.