[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: tramp and ssh-agent / ssh-add
From: |
Michael Albinus |
Subject: |
Re: tramp and ssh-agent / ssh-add |
Date: |
Sun, 30 Mar 2008 13:12:25 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) |
Roland Winkler <Roland.Winkler@physik.uni-erlangen.de> writes:
Hi,
> Usually when I have emacs running on a remote machine, I do this as
> a subprocess of ssh-agent. Then when I establish ssh connections
> via tramp, I want to make sure that I type my password only once via
> ssh-add. What is the cleanest way to do that? Is there some support
> from tramp for that? Right now, my home-made solution uses a
> defadvice for tramp-open-connection-rsh, see the code below.
> However, if tramp-open-connection-rsh is the right entry point for
> what I want to do, it seems to me that a hook might be helpful. Or
> am I missing something else?
I wouldn't do it this way:
- You advice tramp-open-connection-rsh, a function of Tramp 2.0. It
doesn't exist anymore in Tramp 2.1, so you solution isn't future safe.
- I believe that calling ssh-add on-the-fly is not the intended way. You
should call it, before you run emacs "as a subprocess of ssh-agent" on
the remote machine.
- Tramp supports password caching on its own. Install password.el in
your own lisp directory. You could download it from
<http://cvs.savannah.gnu.org/viewvc/*checkout*/tramp/contrib/password.el?revision=1.1.2.1&root=tramp&pathrev=branch-2-0-stable>.
Then you add the following line to your .emacs, after loading Tramp:
(setq password-cache-expiry nil)
> Thanks,
>
> Roland
Best regards, Michael.
- tramp and ssh-agent / ssh-add, Roland Winkler, 2008/03/29
- Re: tramp and ssh-agent / ssh-add,
Michael Albinus <=
- Message not available
- Re: tramp and ssh-agent / ssh-add, Roland Winkler, 2008/03/30
- Re: tramp and ssh-agent / ssh-add, Michael Albinus, 2008/03/30
- Re: tramp and ssh-agent / ssh-add, Roland Winkler, 2008/03/30
- Re: tramp and ssh-agent / ssh-add, Michael Albinus, 2008/03/30
- Re: tramp and ssh-agent / ssh-add, Roland Winkler, 2008/03/30
- Re: tramp and ssh-agent / ssh-add, Michael Albinus, 2008/03/30
- Re: tramp and ssh-agent / ssh-add, Mike Mattie, 2008/03/31
- Message not available
- Re: tramp and ssh-agent / ssh-add, Tim X, 2008/03/31
- Re: tramp and ssh-agent / ssh-add, Michael Albinus, 2008/03/31
- Message not available
- Re: tramp and ssh-agent / ssh-add, Roland Winkler, 2008/03/31