MacOS: Installed openssh via brew, how do I add keys to keychain?
3
votes
2
answers
3773
views
I installed openssh via
brew install openssh
.
I added the following to my .profile:
export SSH_AUTH_SOCK="~/.ssh/agent.$HOST.sock"
ssh-add -l 2>/dev/null >/dev/null
if [ $? -ge 2 ]; then
ssh-agent -a "$SSH_AUTH_SOCK" >/dev/null
fi
And then I have to do the following:
ssh-add ~/.ssh/id_ecdsa_sk
Enter passphrase for /Users/myuser/.ssh/id_ecdsa_sk:
Identity added: /Users/myuser/.ssh/id_ecdsa_sk
even though I have the following in my ~/.ssh/config:
Host *
IgnoreUnknown UseKeychain
UseKeychain yes
AddKeysToAgent yes
IdentityFile ~/.ssh/id_ecdsa_sk
(I had to add the IgnoreUnknown bit b/c the install from brew installs a version that breaks the UseKeychain bit.) But now: how do I wire it up so it adds the key to my keychain?
Help appreciated!
Asked by Mr Mikkél
(133 rep)
May 3, 2021, 05:34 PM
Last activity: Aug 10, 2024, 10:21 AM
Last activity: Aug 10, 2024, 10:21 AM