Web interface to Subversion: WebSVN


by ross at 07:23:25 on October 28, 2011

Install subversion if you need to.


# cd /usr/ports/devel/websvn
# make install clean
# cd /usr/local/www/websvn/include
# cp distconfig.php config.php

Edit /usr/local/www/websvn/include/config.php:


Create /home/svn/websvn.authz:

me = ross
group = user1, user2

@me = rw
@group = r
* =

Create /home/svn/websvn.passwd:

# htpasswd -c /home/svn/websvn.passwd anonymous
# htpasswd /home/svn/websvn.passwd ross
# htpasswd /home/svn/websvn.passwd user1
# htpasswd /home/svn/websvn.passwd user2

Adjust permissions:

# chown svn:svn /home/svn/websvn.*
# chmod 600 /home/svn/websvn.*


<VirtualHost *:80>
        # If you are running apache22-itk-mpm:
        AssignUserID svn svn
        # Otherwise comment it out and add user www to svn group

        ServerName svn.example.com
        ServerAdmin root@example.com
        DocumentRoot "/usr/local/www/websvn"
        ErrorLog "/var/log/httpd-svn.example.com-error.log"
        CustomLog "/var/log/httpd-svn.example.com-access.log" combined

        <Location />
                AuthType Basic
                AuthName "You can login as 'anonymous' with no password"
                AuthUserFile /home/svn/websvn.passwd
                Require valid-user

<Directory "/usr/local/www/websvn">
        Options FollowSymLinks Indexes
        AllowOverride All
        Order Allow,Deny
        Allow from all