Overview
whmDynDns is a PHP script which takes advantage of the WHM JSON API in order to update DNS zone records for pointing subdomains to a server with a dynamic IP address. It can be run using CRON and based on your configuration will add/update A records when your public IP address changes.
Why?
Although I have my production websites hosted remotely I wanted to be able to point development versions to my Linux server hosted at home with a dynamic IP address. i.e. http://www.myapplication.com is hosted remotely but http://dev.myapplication.com is hosted on my own machine. After a little searching I found the WHM JSON API and had to have some fun with it!
Check it out on GitHub at:
Just create a CNAME on DEV and point it to a DynDns hostname then you don’t need to do anything except ensuring that a DynDns client it running. I found running the client on your modem/router is out of site/out of mind as most seem to support it these days.
Thanks for the comment Shaun.. that is definitely an option for some people but not everyone.
Not sure the difference between whm and cpanel. I am a java guy and I only have access to cpanel, so I did very similar thing in Java via cpanel JSON API. Hope it’s useful to people who don’t do scripts. 😉
http://www.sleepingdumpling.com/blog/download/bluejay/