Skip to content

Instantly share code, notes, and snippets.

@ftao
Created December 29, 2012 07:58
Show Gist options
  • Save ftao/4405304 to your computer and use it in GitHub Desktop.
Save ftao/4405304 to your computer and use it in GitHub Desktop.
Install ssh pub key to remote server in one line
cat path/to/pub.key | ssh your.remote.server 'sh -c "mkdir -p ~/.ssh/; cat - >>~/.ssh/authorized_keys"'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment