Thursday, 17 August 2023

unlock ssh key on login

I am on Debian 12, lightdm, Wayland, KDE Plasma


This goes in ~/.profile and unlocks this ssh key on login.

# keep an ssh agent running
export SSH_ASKPASS=ssh-askpass
if [ "$DISPLAY" == ':0' ]; then
if [ -z "$SSH_AUTH_SOCK" ]; then
eval `ssh-agent -s`
fi
ssh-add $HOME/.ssh/stylehouse
fi

At least I think so. Perhaps it's not being done... You can manually:
$ source .profile
It also sets $PATH to include ~/bin

No comments:

Post a Comment