Skip to content

Instantly share code, notes, and snippets.

@IsoLinearCHiP
IsoLinearCHiP / update-ddns.rb
Last active October 20, 2025 15:22 — forked from sixtyfive/update-ddns.rb
DIY dDNS service script using Hetzner's DNS API
#!/usr/bin/env ruby
# on OpenRC systems, place into e.g. /etc/periodic/15min
# (or create /etc/periodic/1min and add line to root's crontab)
# on systemd systems, install it as a timer
# create/find these in Hetzner's DNS admin interface at https://dns.hetzner.com/
API_TOKEN_NAME="..."
API_TOKEN="..."
ZONES=["...", "..."] # TLD; must be registered at https://robot.hetzner.com/domain