Skip to content

wc-zach/do-dyndns

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Digital Ocean Dynamic DNS

This module is designed to update Digital Ocean DNS records with the server's public IP address. The process monitors the server's public IP, and when necessary, creates or updates a DNS A record using the Digital Ocean API.

First you will need to generate a Personal Access Token from Digital Ocean and place it into a do.token file in any of these locations:

# create token file in the project directory to paste into
sudo vi /full/path/to/project/do.token

# create token file in the app etc config to paste into
sudo mkdir -p /etc/illpro/do-dyndns
sudo vi /etc/illpro/do-dyndns/do.token

# create token file in the shell home directory to paste into
sudo vi ${HOME}/do.token

Once you have made the do.token file, you need to finish configuration, in particular you will need to define the domain you want to control with Dynamic DNS using the two required environment variables documented below.

options

DNS_DOMAIN (required)
The domain you want to update.

export DNS_DOMAIN=example.com

DNS_NAME (required)
The subdomain you want to update. Specifically the name of the A record that will be made or updated.

export DNS_NAME=www

DNS_TTL (optional)
Number of seconds the DNS record should be cached for, defaults to 3600 seconds.

export DNS_TTL=100

POLL_FREQUENCY (optional)
Number of seconds between public ip polls, defaults to 8 seconds.

export POLL_FREQUENCY=10

LOG_PATH (optional)
Path where logs should be written, defaults to /var/log/do-dyndns.log. File should be writable by the process owner.

export LOG_PATH=/my/path/do-dyndns.log

notes

About

Digital Ocean DNS Updating Daemon

Topics

Resources

License

Security policy

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •