Use Dropbox to track external IP address

UPDATE (10.29.13): I’ve updated the script to now use icanhazip.com and have also moved it to Github.

Ever want to connect to your home computer from anywhere in the world? Sure there’s services like GoToMyPC, DynDNS that make things pretty easy.

But my question is, why bother with sigining up for another lame service that only do 1 thing. Wouldn’t it be better to use tools you’re probably already using.

The setup:

  1. Dropbox setup on both the server AND client
  2. *nix environment. In my case, Linux server and Mac client

The overview

On your home computer (the server):

  1. Create Bash script to fetch IP and store the results in your Dropbox folder
  2. Schedule script to run every 3 hours via Cron

On your remote computer (the client):

  1. View results file located in your Dropbox folder
  2. Enjoy!

Details / How-to

On your home computer (the server):

On your remote computer (the client):

  1. Open the results file (HomeNetworkIP.txt) located in your Dropbox folder

Bonus:

If you’re feeling extra geeky; you can create another script (stored in the Drobox folder) that uses the results file to connect via SSH.

–special thanks to keefaz over at LinuxQuestions for the IP fetching script.

5 thoughts on “Use Dropbox to track external IP address”

    1. Glad you got it working. I’ve hopefully resolved the issue with the update I just pushed to Github. Thanks for the heads-up.

  1. Great! I tried on OSX and I added these two lines to avoid errors in comparison for the first time, when the destination file doesn’t exist.


    else
    old_ip=1.2.3.4

    Thanks.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>