[EN] Access your raspberry pi SSH anywhere

August 11, 2017 1 minute

If you want to access your Raspberry PI SSH remote without the public IP address, I have a basic solution for you.

  1. First, you need to register at https://ngrok.com/. Login and in the Auth tab, get your Auth token and save it.
  2. Download ngrok to your PI -> https://ngrok.com/download
  3. Unzip it (probably at your Downloads folder)
$ unzip ngrok.zip4, Now we need to set a cron to start ngrok at boot
$ sudo crontab -e

And at the end of file add this:

@reboot sleep 60 && cd /home/pi/Downloads && ./ngrok tcp 22 -authtoken=Your\_Tokken 2>&1 >> /home/pi/reboot.log

Press CTRL + O, ENTER, CTRL + X.

5, Now reboot with:

$ sudo reboot

6, If everything is setup okay, you can go to ngrok.com to show your SSH address and status of PI.