Skip to content

Instantly share code, notes, and snippets.

@simbo
Created November 27, 2022 20:30
Show Gist options
  • Save simbo/58d853e53538194524c145e2090d2a80 to your computer and use it in GitHub Desktop.
Save simbo/58d853e53538194524c145e2090d2a80 to your computer and use it in GitHub Desktop.
Setup ssh keychain for Ubuntu

Setup ssh keychain for Ubuntu

Install keychain

sudo apt-get update
sudo apt-get install keychain

Add keychain commands to .bashrc

# enable keychain for ssh keys
/usr/bin/keychain --quiet $HOME/.ssh/id_rsa
source $HOME/.keychain/$HOSTNAME-sh

Set keychain timeout

518400 minutes = 1 year

keychain --timeout 518400
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment