💻 Software
Use a specified key from ssh-agent
Fresh7 days ago
Mar 15, 202624478 viewsConfidence Score0%
0%
Problem
Along the lines of How to tell git which private key to use? I would like to use a specific ssh key in a given situation. My problem is that even when I specify '-i something' ssh uses the keys from my ssh-agent in the order they are added. My specific situation: I have two github users, each with …
Error Output
Host USER1.git
Hostname github.com
User git
IdentityFile ~/.ssh/USER1.id_rsaUnverified for your environment
Select your OS to check compatibility.
1 Fix
Canonical Fix
Unverified Fix
New Fix – Awaiting Verification
Fix for: Use a specified key from ssh-agent
Low Risk
The point is to use the public key file inside directive. If we specify the private key inside the SSH config, SSH agent will fail to pick the right key if the private key is encrypted. A similar question on stackexchange: https://unix.stackexchange…
Awaiting Verification
Be the first to verify this fix
Sign in to verify this fix