[PLUG] Using ssh-agent and ssh-add
Robert Citek
robert.citek at gmail.com
Thu Mar 30 22:51:34 UTC 2017
On Thu, Mar 30, 2017 at 3:04 PM, Rich Shepard <rshepard at appl-ecosys.com> wrote:
> On Thu, 30 Mar 2017, Robert Citek wrote:
>
>> This is a simplified version of what I have in my ~/.profile :
>>
>> [ -z "$SSH_AGENT_PID" ] && tty -s && exec ssh-agent bash --login
>> [ -n "$SSH_AGENT_PID" ] && tty -s && {
>> echo -e "\nAdding keys to ssh-agent ..."
>> ssh-add ~/.ssh/*_rsa
>> echo
>> ssh-add -l
>> }
>
> Robert,
>
> Now that's very interesting.
>
>> Try this on a test user account before integrating it into your real
>> account.
>
> Setting up a test user needs to wait until I have some time to devote to
> this.
You can try the manual way by typing these two commands after you have
logged in to your account:
exec ssh-agent bash --login
ssh-add ~/.ssh/*_rsa
The other stuff is overhead that is needed when in the ~/.profile.
Regards,
- Robert
More information about the PLUG
mailing list