Public IP Address Notification Emailer

Sometimes you want to know the IP address of a remote server, but it can have a dynamic address that can change. There are services that can provide this service, but I wanted something free and simple that also provided a heartbeat message from the remote server.

The idea is to have a bash script on a cron job that will call a remote server. This remote server will then know the public IP address of the caller and can send the information to an email address. Now the email messages will have the remote IP address and the emails also serve as heartbeat messages.

I have put the code I use to do this in GitHub for anyone that may want to do something similar.

https://github.com/conciseusa/public-ip-notification-emailer

A short coming of this system is you need to wait for the next cron run to get a changed address. That was not an issue in my application.

This entry was posted in Uncategorized and tagged , , , , . Bookmark the permalink.

Leave a Reply

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