Cheatsheet for Passwordless SSH Access to SourceForge for EPICS V4 Development

These instructions were written for programmers of the epics-pvdata sourceForge project, but are probably general to any sourceForge project.

They're based on reference instructions at SourceForge. Also, they're written for Mac OS X command line, but any unix is probably the same, so for "mac" read, your local machine.

  1. On your mac in your user account, execute ssh-keygen and follow the prompts. You want a the file ~/.ssh/ when you've finished (see the instructions at SourceForge).

    % ssh-keygen -t dsa -C ""
  2. Install your key into your sourceforge account:

    1. If you can, use ssh itself (see below if this doesn't work for you):

      % ssh -i /Users/greg/.ssh/'s password: ******
      Welcome to *
      This is a restricted Shell Account
      You cannot execute anything here.
      Connection to closed.
    2. Or, if that above doesn't work, use the manual mechanism given on your Sourceforge Account Services page. Copy and paste the contents of your ~/.ssh/ file, as created by ssh-keygen above, into the window provided in your account services page as described in "SSH Key Posting" off the reference instructions at SourceForge.

  3. Update your ssh config file to specify that for the epics-pvdata sourceforge site at least, to use passwordless authentication. That is, add the following lines to your own ~/.ssh/config file:

    PreferredAuthentications publickey
    IdentityFile /Users/<your computer username>/.ssh/id_dsa     <==edit
    User <your sourceforge username>      <== edit
  4. Test it. hg pull should work without a password

Greg White, SLAC, PSI
Last modified: Sun Dec 11 17:49:22 PST 2011