0xdeadbeef
0xdeadbeef

Reputation: 4140

How do I connect to a remote svn server?

Heres the current setup.

Home PC ---/ Internet /---> Work Proxy Server --/ LAN /--> SVN server

I want to connect to the work svn server commit changes, update and checkout from the home PC.

I can tunnel to my Work SVN PC (not the service) with no problems, which I currently use with VNC (using PuTTY).

Currently using Tortoisesvn for a client.

Thanks for any help!

Upvotes: 0

Views: 18001

Answers (3)

PauloT
PauloT

Reputation: 81

The previous answers may be correct, but are more complicated than necessary. If you specify your repository using the syntax svn+ssh://user@host/path/to/repository, tunneling details will be taken care of, as long as you meet the following requirements:

  • you can ssh to the server holding the repository
  • you would be able to run 'svnserve' on this server
  • you got ssh or a similar command-line utility on your windows client machine

The last item may involve a bit extra work. I had success by:

  1. installing Cygwin (with 'openssh' + 'openssl' packages)
  2. adding the following line to the [tunnels] section of the SVN 'config' file(*): "ssh = /cygwin/bin/ssh -q " (no space at the beginning of the line).

(*) You can find it in c:\Documents and Settings\user\Application Data\Subversion, or by going to the TortoiseSVN Settings > General menu, and clicking the 'Edit' button.

Upvotes: 0

rmeador
rmeador

Reputation: 25724

Assuming your work proxy machine has access to the SVN server, you would set up a tunnel like this with regular SSH: ssh -L localport:svnserver:svnport username@proxyserver. You'll need to figure out the equivalent options for PuTTY, perhaps by using that link Ben S provided. Once you've set up the tunnel, all your SVN operations will be going through localport on your local computer, so you'll need to set up Tortoise to treat your local machine on that port as the SVN server (using either a new checkout or an svn switch --relocate on an existing working copy.

Upvotes: 1

Ben S
Ben S

Reputation: 69412

You need to configure a tunnel port in PuTTY so that you'll connect to localhost:someport on your home PC, and PuTTY will tunnel all traffic between the two.

Depending on the SVN server setup you'll want to use either port 80 (http:), 443 (https:) or 3690 (svn:).

This tutorial is slightly outdated, but still applies here.

Upvotes: 2

Related Questions