I've been working for a while now trying to understand SVN better. I am working with a Mac OSX Lion server. I've been able to set up and getting a SVN running on the machine and make it so I can check in and out documents. However, I want to make it accessible to additional services over the internet,so while many of my colleagues and I are traveling, we can still work in conjunction. I have forwarded port 3690 (I believe that's the SVN port) and the port for ssh was set up previously.
I installed the SVN Repository at /Library/Subversion/Repository/, and I have Versions and Terminal on the server to test with. I can connect by using the file:// path parameter but I can not connect using svn+ssh://username@localhost/MyProject.
I know for a fact that I can connect through ssh and the error is "No repository found". I'm guessing I need a different path, but all the Mac OS articles I've read only tell how to set it up on the host not for use over LAN or externally.
Any ideas or thoughts are greatly appreciated. As a reference to the steps I've taken below are some of the links to articles I was working from.
First of all, make sure that your Mac firewall isn't blocking you. Can you remotely log in via
sshfrom another system to your system? If not, go to System Preferences, select the Security and Privacy preference, then select Firewall. You'll need to click the Advanced... button.Once there, make sure Remote Login (SSH) is active through the Firewall.
Once you've allowed
sshaccess to your Mac, you'll need to make sure that you havesvn+sshsetup correctly. Try from your own Mac to access the repository viasvn+ssh://and not viafile://. If you can't do that, you don't havesvn+sshsetup correctly.Setting up Subversion to use
svn+sshis the trickiest of the four ways to access a Subversion repository. Unlikesvn://andhttp://, the repository server isn't running until the user logs into your system.When a user connects vis
svn+ssh, they immediately start upsvnservein order to access the Subversion repository (that's thesvnpart ofsvn+ssh).Because
svnserveruns as the user who usedsshto access the repository, each directory and file created in the physical repository directory will be owned by that user. Thus, you need to make sure that all users who have access to that repository are in the same primary group, and any created files or directories in the Subversion repository directory are read/writeable by that group.In order to ensure that, you need to take the following steps:
chgrpcommand.chmodcommand to make sure the entire directory tree are read/writeable by that Subversion group.umaskto002or0002instead of the default022or0022. This way, when the user creates a new directory or file in the repository, it can be read and written by any other user in the group. Otherwise, one user will create a change, but other users won't be able to make modifications.Take a look at these links from the on line Subversion manual: