go-dyndns is a DynDns client written in Golang (yes, very creative name, I know 😄 )
go-dyndns is designed to be run inside a Docker container. Therefore, configuration is done via environment variables. The following is an example Docker compose file:
version: '3.6'
secrets:
password:
file: password.txt
services:
go-dyndns:
image: ghcr.io/sunnjek/go-dyndns
restart: unless-stopped
secrets:
- password
tmpfs: /tmp
environment:
# To instead retrieve the public IP from your FritzBox, use this instead of IPCHECK_URL:
# CLIENT_IPPROVIDER: fritzbox
IPCHECK_URL: 'http://checkip.dyndns.com'
CACHE_FILE: /tmp/go-dyndns.cache
DYNDNS_DOMAINS: example1.com,example2.com
DYNDNS_HOST: members.dyndns.org
DYNDNS_PASSWORDFILE: /run/secrets/password
DYNDNS_USER: user
The following environment variables can be used:
CLIENT_IPPROVIDER
: Can be eitherweb
orfritzbox
, default isweb
. Controls how the public IP is determined.CLIENT_DELAY
: Delay between updates. Defaults to 10 minutes (10m
)CLIENT_ENABLEIPV6
: Whether IPv6 is enabled or not (only available with FritzBox provider). Can be eithertrue
orfalse
.FRITZBOX_HOST
: The hostname of the FritzBox. Defaults tofritz.box
. Only used withfritzbox
providerIPCHECK_URL
: The URL to use to determine the public IP address. Only used withweb
providerCACHE_FILE
: Specifies the location for the cache file. If not specified, the cache will be stored in memoryDYNDNS_DOMAINS
: Comma-separated list of domains to updateDYNDNS_HOST
: Host to which to send the update request.DYNDNS_USER
: The username with which to authenticateDYNDNS_PASSWORDFILE
: Path to a file containing the password with which to authenticate. Use a docker secret for this one (see example above)LOG_LEVEL
: The level used for logging. Potentially useful for diagnosing problems (if I can be bothered to add more logs, that is 😄 )