Reference and guides to build kick ass raspberry pi projects.
View the Project on GitHub codingforentrepreneurs/Pi-Awesome
This is a quick reference on how to ssh into a host server without using a password. It’s all done through using public
keys generated by ssh-keygen
ssh-keygen -t rsa -b 4096
Windows users must use the manual process below.
REMOTE_HOST=pi@raspberrypi ssh-copy-id $REMOTE_HOST
For linux/macos
REMOTE_HOST=pi@raspberrypi
cat ~/.ssh/id_rsa.pub | ssh $REMOTE_HOST "mkdir -p ~/.ssh && chmod 700 ~/.ssh && cat >> ~/.ssh/authorized_keys && chmod 600 ~/.ssh/authorized_keys"
Update
REMOTE_HOST
to your<user>@<remotehost>
such aspi@192.168.86.24
For windows
$env:RemoteHost="pi@raspberrypi"
cat ~/.ssh/id_rsa.pub | ssh $env:RemoteHost "mkdir -p ~/.ssh && chmod 700 ~/.ssh && cat >> ~/.ssh/authorized_keys && chmod 600 ~/.ssh/authorized_keys"