Script to periodically update the DNS records on DigitalOcean (default 10 minutes)
- Curl
- Python for pretty print json
- Systemd for timer
- Create DNS record
- Create API token (Read + Write) at https://cloud.digitalocean.com/account/api
- Find domain record id
export DO_TOKEN=abc123...
export DO_DOMAIN=example.com
./list-domains.sh [page]
export DO_RECORD_ID=445653
# Test
./update-dns-record
- Install with
./install.sh
- Will copy
update-dns-record.sh
to/opt/digitalocean-ddns/
and replace the ENV variables with the actual values - Will copy systemd unit and timer to
/etc/systemd/system/
and activate it
- Will copy