SVN insight
Apache virtual host for SVN
Expose a single Subversion repository via its own domain with a minimal Apache vhost configuration and SSH commands.
Repository hosting recipe
Create the repository, point Apache to the SVN path, and restart the web server—everything runs from the SSH console.
1. Create an empty repository
Run the following commands on the server to prepare a repository folder:
cd ~
mkdir svn
cd svn
svnadmin create apachesvn
Now you have an empty repository named apachesvn. Importing a dump is also possible using our SVN dump & restore guide.
2. Configure the Apache vhost
Edit the virtual host file and paste the snippet below; replace the IP, domain, and path with your values.
nano /etc/apache2/sites-enabled/vhosts
<VirtualHost 192.168.1.112:80 >
ServerName "svndirect.testserver.saas-secure.com"
<Location />
DAV svn
SVNPath /home/anyuser/apachesvn
</Location>
</VirtualHost>
This configuration maps the domain directly to the repository root via SVNPath and enables DAV svn.
3. Restart Apache
Apply the change by restarting the service:
/etc/init.d/apache2 restart
After the restart, the repository is available over the specified domain.
Need more help?
Our Subversion hosting team can handle the setup for you, including access control adjustments. Browse the managed hosting options or reach out with a support ticket.