| 1 |
#!/bin/sh |
| 2 |
|
| 3 |
set -e |
| 4 |
|
| 5 |
ssh_config="$1" |
| 6 |
|
| 7 |
ssh-keygen -q -f $HOME/.ssh/id_rsa -P '' |
| 8 |
ln .ssh/id_rsa.pub $HOME/.ssh/authorized_keys |
| 9 |
# ssh-keyscan burps comment line to stderr, drop it. |
| 10 |
ssh-keyscan -H localhost >$HOME/.ssh/known_hosts 2>/dev/null |
| 11 |
cp $ssh_config $HOME/.ssh/config |
| 12 |
|