Friday, January 11, 2008

Apache and Subversion

Well, nothing good comes easy. Here's a very abbreviated recipe for setting up Apache as a SVN front-end, listening on port 7382.

In your apache source directory:
./configure --prefix=/usr/local/apache_svn --enable-mods-shared=all --with-included-apr --with-port=7382
make
make install

Following is because subversion puts its apache modules in apache2 by default.
cd /usr/local/apache_svn/modules ; ln /usr/local/apache2/modules/*svn.so .

In /usr/local/apache_svn/conf/httpd.conf uncomment:
Include conf/extra/httpd-dav.conf in httpd.conf

Add to httpd.conf:
LoadModule dav_svn_module modules/mod_dav_svn.so

DAV svn
SVNPath /absolute/path/to/repository

User svn_user #Have apache run as a user with rw access to svn repository.
Group svn_user

No comments: