💾 Archived View for sdf.org › beni › tech › sshagent.gmi captured on 2023-12-28 at 16:43:02. Gemini links have been rewritten to link to archived content
⬅️ Previous capture (2023-09-08)
-=-=-=-=-=-=-
Start ssh agent. The reason we need eval is the fact that the ssh-agent command returns environment variables which we need in the current session for SSH to find the agent.
eval $(ssh-agent)
Now we add the ssh keys we want to use
ssh-add
This by default adds the ~/.ssh/id_<algorithm> keys. If you want to add others, you have to specify them explicitly
ssh-add ~/.ssh/<your-private-key>