Tuesday, February 10, 2009

Installing Web Frameworks, part 2: SVN

  1. install apache2: sudo apt-get install apache2
  2. install svn: sudo apt-get install subversion
  3. add a svnusers group: sudo groupadd svnusers
  4. enabled visibility for all users: Alt-F2 to bring up run, and then type in gconf-editor. Within this, open apps/gnome-system-tools/users, and check showall.
  5. add me, root and www-data to svnusers group: I cheated and did it via the GUI!
  6. create root repositories directory: sudo mkdir /srv/repositories
  7. assign repositories to www-data & svnusers: sudo chown -R www-data:svnusers /srv/repositories
  8. change mod: sudo chmod -R g+rws /srv/repositories
  9. create rails repo, in /srv/repositores: svnadmin create rails
  10. repeat steps 7 & 8, to ensure that apache owns and controls all the files in the repo
  11. install libapache2-svn: sudo apt-get install libapache2-svn
  12. restart Apache2: sudo /etc/init.d/apache2 restart
  13. edit /etc/apache2/mods-available/dav_svn.conf. Add in the contents specified here. The list is below.
  14. create the password file /etc/subversion/passwd: sudo htpasswd -c /etc/subversion/passwd matthew. Don't forget this, or you'll end up with weird permissions errors in local and remote clients, including things along the lines of "Server sent unexpected return value (500 Internal Server Error) in response to MKACTIVITY request"

<Location /svn>
DAV svn
SVNParentPath /srv/repositories
SVNListParentPath On
AuthType Basic
AuthName "Synesis Web Subversion Repository"
AuthUserFile /etc/subversion/passwd
Require valid-user

No comments:

Post a Comment