User Tools

Site Tools


svn:svn_howto

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Last revisionBoth sides next revision
svn:svn_howto [2008/02/23 16:58] devasvn:svn_howto [2008/02/23 19:52] deva
Line 4: Line 4:
  
 ====Installing SVN==== ====Installing SVN====
-Useflags: ''apache2'' ''nowebdaw''+Useflags: ''apache2'' ''-nowebdav''
 <code> <code>
 emerge -va subversion emerge -va subversion
 </code> </code>
  
 +<code>
 +* Subversion Server Notes
 + * -----------------------
 + 
 + * If you intend to run a server, a repository needs to be created using
 + * svnadmin (see man svnadmin) or the following command to create it in
 + * /var/svn:
 + 
 +     emerge --config =dev-util/subversion-1.4.6
 + 
 + * Subversion has multiple server types, take your pick:
 + 
 +  - svn over ssh:
 +    1. Fix the repository permissions:
 +         groupadd svnusers
 +         chown -R root:svnusers /var/svn/repos/
 +         chmod -R g-w /var/svn/repos
 +         chmod -R g+rw /var/svn/repos/db
 +         chmod -R g+rw /var/svn/repos/locks
 +    2. create an svnserve wrapper in /usr/local/bin to set the umask you
 +       want, for example:
 +          #!/bin/bash
 +          . /etc/conf.d/svnserve
 +          umask 002
 +          exec /usr/bin/svnserve ${SVNSERVE_OPTS} "$@"
 + 
 +  - http-based server:
 +    1. edit /etc/conf.d/apache2 to include both "-D DAV" and "-D SVN"
 +    2. create an htpasswd file:
 +       htpasswd2 -m -c /var/svn/conf/svnusers USERNAME
 + 
 + * If you intend to use svn-hot-backup, you can specify the number of
 + * backups to keep per repository by specifying an environment variable.
 + * If you want to keep e.g. 2 backups, do the following:
 + * echo '# hot-backup: Keep that many repository backups around' > /etc/env.d/80subversion
 + * echo 'SVN_HOTBACKUP_NUM_BACKUPS=2' >> /etc/env.d/80subversion
 +
 +</code>
svn/svn_howto.txt · Last modified: 2008/02/24 10:50 by deva