You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Erik Hollensbe 2dbcd28f9f install ruby if it's not installed already 9 years ago
attributes first commit to separate repo 10 years ago
files/default first commit to separate repo 10 years ago
recipes install ruby if it's not installed already 9 years ago
templates/default first commit to separate repo 10 years ago updated readme for dynamic_dns 10 years ago
metadata.rb make berkshelf happy 9 years ago

dynamic_dns: control DNS management without external services

Basically this has one recipe at this point, which installs a script which gets set in cron.

This script:

  • Consults with a jsonip (or alike, server-side will be a part of this eventually) service to get the external IP of the host.
  • Sends an nsupdate to a DNS server and updates an A record with that IP address.

This is a slightly modified version of the script blogged about here.

Recipe Information

The recipe is called dynamic_dns::install_nsupdate and it takes several attributes:

  • dns/hostname: the hostname to update with any IP address change.
  • dns/server: the DNS server's address.
  • dns/secret: the secret key used by nsupdate to authenticate with the DNS server.
  • dns/zone: the zone to update on the DNS server.
  • dns/jsonip_service: the json IP service url (default:

Unless specified there are no defaults for any of these keys and the recipe will raise ArgumentError for any missing keys before trying to do anything. Trust me, this is in your best interest. :)

Future plans are to implement recipe tooling for the nginx/unicorn/rack side of this, but as of this writing this does not exist.


Currently this recipe only supports ubuntu and debian -- likely due to package name differences. Happy to accept pull requests for other systems.


  • Fork the project
  • Make your edits
  • Be sure to not change anything in metadata.rb without prior permission.
  • Send a pull request.


Erik Hollensbe