Skip to content

Instantly share code, notes, and snippets.

@micjamking
Last active October 24, 2017 05:29
Show Gist options
  • Save micjamking/8469530 to your computer and use it in GitHub Desktop.
Save micjamking/8469530 to your computer and use it in GitHub Desktop.
[Command Line] Add Public SSH Key to Remote Server in a Single Command

Copy SSH Pubkey to Remote Server

$ cat ~/.ssh/id_rsa.pub | ssh user@hostname 'cat >> .ssh/authorized_keys'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment