customizing svnserve for svn+ssh
From: Matthew Beals <mjbeals_at_mtu.edu>
Date: Fri, 9 Sep 2011 21:13:01 -0400 (EDT)
I have two sets of repos setup... common repos and user repos. On the machine acting as the svn host, I have the common repos stored in /repos while the user repos are in /home/<username>/.repos/
I'm attempting to simplify svn+ssh access such that:
svn+ssh://<server>/Code/some_project_repo serves up /repos/Code/some_project_repo
I took the example of writing a shell script in /usr/local/bin that sets the umask and calls svnserve and modified it to include this path tinkering. Here is that script:
##############################################
umask 002
PATH="$@"
if `/usr/bin/ypcat passwd | /bin/egrep -q $PATTERN` ; then
exec /usr/bin/svnserve "$PATH" -r "$ROOT"
It just compares the first directory passed in against the users in the NIS domain and if it finds a match, builds a new Path and root path to the repos. It works just fine on the command line when I pass it paths and echo back out the parts, but when I attempt to actually run it (by accessing a repo with svn+ssh), $PATH does not get set to the path being passed in... it is just set to '-t'. However, when I try to access a common repo (where PATH is left unadulterated), it serves up the repo just fine. Is the path being passed encoded somehow? Is there are way to access it?
thanks,
----------------------------------------
|
This is an archived mail posted to the Subversion Users mailing list.
This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.