Wednesday, December 17, 2008

Eclipse Subversion access from behind a proxy

It is for the very first time that I post anything to solve a M$ platform problem, but this one is to allow the usage of a tool that is worth the shame.

The problem when connecting to any svn repository is that you are getting this message (example is from an open source project AbTLinux):

RA layer request failed
svn: PROPFIND request failed on '/svnroot/abtlinux'
svn: PROPFIND of '/svnroot/abtlinux': Could not resolve hostname `abtlinux.svn.sourceforge.net': The requested name is valid and was found in the database, but it does not have the correct associated data being resolved for. (https://abtlinux.svn.sourceforge.net)

The problem is that you need to pass through a proxy and in my case, this needs to happen with a user name and password authentication. This is done in the Subversion server configuration file. For both Linux, osX (Mac) the file is in the same location, for M$ it is in a bit different location. Both show you how to fix this for the user only. Should you wish to do this for the entire machine you will need to locate the central server configuration file:

#
# For Windows: %USERPROFILE%\Application Data\Subversion\servers
#

#
# For Linux or osX: ~/.subversion/servers
#

[global]
http-proxy-host = <proxy.server.name>
http-proxy-port = <some_port_number>
http-proxy-username = <your_user_name>
http-proxy-password = <your_password>


Once you set these for the user, ensure your SVN-plugin in Eclipse is using the Default location for the configuration settings and you should be able to connect to both http and https repositories.

5 comments:

  1. thank you for posting it!
    Vic

    ReplyDelete
  2. I would just like to update you on a few small items.
    1. The SERVER file on Windows7 systems is in %USERPROFILE%\AppData\Roaming\Subversion

    2. If you were crazy enough to try to fill in and use Eclipses built in proxy settings (they don't work for those use NTLMv2 proxy authentication) make sure you set it back to DIRECT as subversive will attempt to use these first.

    ReplyDelete
    Replies
    1. Of course, once you set Eclipse to direct you can no longer update the Android SDK if you are behind a firewall/proxy !!

      Delete
  3. first: thanks for the help. I had done this on M$ before but just switched to mac and didn't know where to find the svn servers file.
    second: i love the hudsucker proxy

    ReplyDelete
  4. Just to have it clear for me, is the SVN behind a proxy server in this blog? Or are you connecting behind a proxy to an SVN server?

    I have the problem that I can browse my (https) SVN server with a browser, but as soon I try to connect (via subversive) to my SVN server it fails. I can install software from the eclipse market place (in eclipse), so my proxy is configured correctly.

    ReplyDelete