Using CVS and SSH hints and tips
--------------------------------


I want to use CVS and SSH, but it only lets me use the default key!  Trying
to set CVS_RSH to /usr/bin/ssh -i  yields an error message.
---------------------------------------------------------------------------

If you want to use a key other than the default for CVS, try the following:

##### cvs-ssh #####
#!/bin/sh
exec /usr/bin/ssh -x -i $HOME/.ssh/my-cvs-key $@
###################

You will need to "export CVS_RSH=/path/to/cvs-ssh" in .login or whatnot.  If
you're using one of the default keys (id_dsa, id_rsa, identity are the
initial defaults in a clean OpenSSH installation), then you can simply use
"export CVS_RSH=ssh" as stated in CVS docs.



I signed the key like my anal system administrator told me to.  Now what?
Instead of typing in a password every time I ssh in, I need to type in a
passphrase!  Forget even trying to use CVS_RSH=ssh!
-------------------------------------------------------------------------

Good for you!  It's highly inadvisable to leave your keys unsigned, for
security's sake.  Especially on a multi-user system, but even on a personal
workstation.  If you want to make your life easier, you will need to run
ssh-agent at login.  Then add the appropriate key to that agent via ssh-add.

The following will get you started in X windows, modify to taste.  This was
tested under RedHat 6.x and 7.x with OpenSSH client.


##### $HOME/.xsession #####
#!/bin/sh
eval `ssh-agent -s`
exec $HOME/.xsession.real
##########################

##### $HOME/.xsession.real #####
#!/bin/sh
ssh-add $HOME/.ssh/id_dsa $HOME/.ssh/my-cvs-key < /dev/null
exec /usr/share/apps/switchdesk/Xclients.kde
################################

As you can see, here I'm running KDE as my session manager, and I also need
to explicitly specify any of the default keys mentioned above (in this case,
I also wanted to use id_dsa for some other project).


The above lets me use CVS (actually Cervisia GUI for CVS) with Sourceforge
once I uploaded my public keys to my personal profile.


Dan Widyono