Warning: This blog entry was written two or more years ago. Therefore, it may contain broken links, out-dated or misleading content, or information that is just plain wrong. Please read on with caution.
Setting up a apache for a SVN Repo is well documented, but only for single repositories. What if you want multiple?
Define a single repository in vhosts
In all the documentation on subversion, when the author details setting up the location of a repository they use something like this.
This results in you being able to reference the repository "myrepository" by visiting the url:
This works fine when you have a single repository, but what if you have several.
SVN Parent Path
Now you could simply copy and paste the Location directives for each repo....or you could use Parent Path directive. The SVNParentPath directive allows us to define the path to the parent folder in which all our repositories are located. To use it see the following example.
Note the addition of the SVNListParentPath directive and the change from SVNPath to SVNParentPath. These changes create a root directory reference which lists all our repositories in the referenced location (provided they are all stored in the same location of course).
Accessing the repository listing is now as simple as visiting the url "http://yourdomain.com/svn/". You can then view all the listed repositories and click through to each one. The previous url for the "myrepository" repo is still valid, we just no longer have to explicitly define it in the location section.