Releases: qdm12/ddns-updater
Releases · qdm12/ddns-updater
v2.8.2
Fixes
- Common update mechanism:
- do not update if public IP address is within multiple IP addresses resolved
- IPv6 hostname resolution fixed (it was previously only resolving IPv4)
- Porkbun:
- Gandi.net:
- update API endpoint
- leave ttl unmodified if the user does not specify it
- DonDominio: wildcard support fixed
- Netcup.de: allow wildcard domains (#863)
- GCP: prevent crash for missing record (#846)
- NoIP: handle response body messages before checking HTTP status code
- Trim space and lower case all HTTP response 'plain' bodies
- OVH: handling of invalid JSON error bodies fixed
- Aliyun: error context fixed when handling bad request errors
Documentation
- GoIP: fix domain field documentation
- eTLD must be goip.de or goip.it, not eTLD+1
- remove old
domain
optional parameter documentation
- DuckDNS: fix domain documentation on eTLD being duckdns.org
v2.8.1
v2.8.0
Pre-built binaries are attached at the bottom of this release notes in the Assets section. Feel free to 👍 the release!
Features
- Read both domain ("eTLD+1") and owner (aka host) from the
domain
field- retro-compatible change,
host
orowner
field still work if set - documentation updated to only use the
domain
field
- retro-compatible change,
- Use umask from operating system to set permissions on created files
UMASK
option to configure a custom umask value to use
Fixes
- PublicIP HTTP echo: remove
google
provider which no longer works - Porkbun:
- noip: force
useProviderIP
tofalse
when using IPv6 - Don Dominio: remove unneeded
name
field - Upgrade github.com/qdm12/gosettings from v0.4.1 to v0.4.4-rc1
- Bump github.com/breml/rootcerts from 0.2.17 to 0.2.18 (#814)
Changes
- Deprecate
provider_ip
config field completely- change should not affect any existing configurations
- change solves issues with dual stack updates (#767)
- this option was unneeded and added unneeded complexity
Documentation
- Readme: add instructions to build latest binary
- Documentation updated to only use the
domain
field for both the domain and owner/host. - Readme: add
README.md
anddocs/
versioned links for each recent releases - Readme: add AUR package name to features list section
- Goip: fix documentation for the
host
parameter field - OVH: link to page to retrieve the
consumer_key
value - Porkbun: fix discrepancy in parameter field names
- Readme: remove outdated Kanban Github board link
Maintenance
Code health
- Rename
cmd/updater
tocmd/ddns-updater
to have binaries named asddns-updater
by default internal/providers
:- split out settings validation in its own pure function
- move domain check to each provider validation function
- typo 'agend' fixed to 'agent' in user agent banned error (#790)
internal/models
: remove unusedDomainHost
struct- rename
host
toowner
- Retro-compatible change,
host
field still works - Code updated to use owner variable name
- Retro-compatible change,
internal/providers/porkbun
: refactor API code to use a generichttpPost
functioninternal/persistence/json
: change mutex to be non embedded in Database struct- CI: ignore
duckdns.org
for links check
Dependencies
- Drop dependency on github.com/chmike/domain
- Bump golang.org/x/net from 0.26.0 to 0.29.0 (#806)
- Bump golang.org/x/oauth2 from 0.21.0 to 0.23.0 (#802)
- Bump github.com/qdm12/gosplash from 0.1.0 to 0.2.0 (#783)
- Bump github.com/miekg/dns from 1.1.61 to 1.1.62 (#815)
- Bump golang.org/x/mod from 0.18.0 to 0.21.0 (#801)
- Bump github.com/go-chi/chi/v5 from 5.0.12 to 5.1.0 (#755)
- Upgrade temporary build image Alpine from 3.19 to 3.20
- Bump docker/build-push-action from 5 to 6 (#747)
- Bump DavidAnson/markdownlint-cli2-action from 16 to 17 (#811)
v2.7.1
ℹ️ This is a bugfix release built with fixes only on top of the v2.7.0 program
Fixes
- publicip/http: remove google provider which no longer works
- Porkbun: fix wildcard behavior and alias deletion
- Noip: force useProviderIP to false for IPv6
- Don Dominio: remove unneeded
name
field
Documentation fixes
- readme: add
readme
anddocs/
versioned links - goip: fix documentation for the
host
field
Other minor fixes
- Upgrade github.com/qdm12/gosettings from v0.4.1 to v0.4.4-rc1
- Upgrade github.com/breml/rootcerts from 0.2.17 to 0.2.18
- CI: ignore duckdns.org for links check
v2.6.1
ℹ️ This is a bugfix release built with fixes only on top of the v2.6.0 program
Fixes
custom
: url building fixed⚠️ - Web UI: IPs chronological order fixed (reverse) 🖱️
- IP echo: allow custom urls for http ip providers
inwx
: allow wildcard hostsionos
: wildcard handlingname.com
- update root domain record fixed
- detect existing root domain records
noip
- IPv6 handling fixed
- handle
useproviderip
set to true correctly
porkbun
: wildcard update fixed
v2.7.0
Pre-built binaries are attached at the bottom of this release notes in the Assets section. Feel free to 👍 the release!
Features
- Web UI: improvements and fixes (#687)
- changeip.com support
- route53 simple routing support (#715)
CONFIG_FILEPATH
(or--config-filepath
) option to specify a configuration file path- healthchecks.io
- fail and exit codes support
HEALTH_HEALTHCHECKSIO_BASE_URL
option
- container:
/updater/data
built-in with correct ownership (#634) publicip/http
:- add multiple providers for all IP versions: icanhazip, ident, nnev, wtfismyip, seeip.org
- add changeip for ipv4orv6
publicip/info
: add ip2location.io providerSERVER_ENABLED
option defaulting toyes
- Print version when the first argument is
version
,-version
or--version
- server: serve root at /rooturl on top of /rooturl/
- validate domain strings for providers using it (#638)
Fixes
See v2.6.1 for fixes incorporated in this release compared to v2.6.0
- container: rename
/updater/app
to/updater/ddns-updater
so it can easily be found in running processes (see #729) - health server: only run it when running in a container
- trim spaces from each "host" value
cloudflare
: prevent empty "key" value if "email" is setgodaddy
: link to comment when status code 403 is receivedovh
: add no host case handling
Documentation
- readme: update for standalone binaries
- update description and title to be generic and non-specific to containers
- describe availability as container image and prebuilt binaries
- split features in subsections
- readme: fix public ip echo custom url prefix
url:https://
instead ofhttps://
- readme:
RESOLVER_ADDRESS
description improved - readme:
HEALTH_HEALTHCHECKSIO_UUID
description improved - readme: reference Qnap setup guide (issue #708)
- readme: better explain container directory and file creation
- readme: fix missing allinkl document link
- contributing document with example provider
- add example provider in code and docs/example.md
- merge contributing guides together
- add contributing section on adding a new provider
- contributing: change 'remote containers extension' to new 'dev containers extension' (#696)
- devcontainer: change 'remote containers extension' to new 'dev containers extension'
docs/infomaniak.md
: add missing details and guide (#677)docs/
: fix typoidentifiersuffix
->identifier suffix
Maintenance
Coding
- migrate to service architecture with github.com/qdm12/goservices (#743)
porkbun
: add context to top level errors- linter
- remove invalid configuration file fields
- add multiple linters
cloudflare
: unexportcreateRecord
method- public ip: better error messages stating the provider type if unknown
- cmd/updater: split main function into smaller functions
gcp
: validate credentials JSON object has "type" field- change ttl type from int/uint/int32 to uint32
Dependencies
- drop Google SDK dependency
- depend only on golang.org/x/oauth2
- reduce program size from 17MB to 11.5MB
- bump github.com/qdm12/gosettings from 0.4.0-rc9 to 0.4.1 (#683)
- bump github.com/breml/rootcerts from 0.2.14 to 0.2.17 (#612, #631, #741)
- bump github.com/miekg/dns from 1.1.57 to 1.1.61 (#600, #745)
- bump golang.org/x/mod from 0.14.0 to 0.18.0 (#637, #736)
- bump github.com/go-chi/chi/v5 from 5.0.11 to 5.0.12 (#654)
- bump github.com/stretchr/testify from 1.8.4 to 1.9.0 (#662)
- Upgrade Go from 1.21 to 1.22
CI
- bump actions/checkout from 3 to 4 (#599)
- bump actions/setup-go from 2 to 5 (#630)
- bump crazy-max/ghaction-github-labeler from 4 to 5 (#596)
- bump DavidAnson/markdownlint-cli2-action from 14 to 16 (#629, #688)
- bump docker/login-action from 2 to 3 (#597)
- bump docker/setup-qemu-action from 2 to 3 (#584)
- bump golangci-lint to v1.56.2
- bump goreleaser/goreleaser-action from 5 to 6 (#737)
- bump peter-evans/dockerhub-description from 3 to 4 (#610)
- pin docker/build-push-action to v5
v2.6.0
Features
- Support CLI flags 🎏 (equivalent to environment variable names)
- Automated binaries releasing on GitHub for commonly used platforms
- IPv6: add JSON parameter
ipv6_suffix
and deprecateIPV6_PREFIX
(retro-compatible change) (#611) - Public IP fetching 📥
- DNS fetching uses DNS over TLS (DoT) only 🔒,
google
removed due to no support for DoT - Ipify support for HTTP "IPv4 or IPv6" fetching
- Remove NoIP HTTP option (only plaintext HTTP fetching)
- Add Spdyn for HTTP IPv4 or IPv6 fetching
- Add ipleak for all HTTP modes
- DNS fetching uses DNS over TLS (DoT) only 🔒,
- Existing providers features ♻️
- DonDominio: add support for subdomains and wildcard host values
- Porkbun: json decode error messages for log messages
- Custom provider ✏️ (bugged, fixed in next release v2.7.0)
- Sends HTTP GET request to url given with ip information
- Configurable ipv4 and ipv6 query parameter keys
- Configurable response success detection with a regex
- Treat non status OK 200 responses as failures
- 🆕 Providers
- Shoutrrr 📢
- Bumped from v0.7.0 to v0.8.0
- Add
SHOUTRRR_DEFAULT_TITLE
, disableSHOUTRRR_PARAMS
and only add&title=
parameter to shoutrrr address if it's not set in the address already
- healthchecks.io support with configuration option
HEALTH_HEALTHCHECKSIO_UUID
🩺 - Logging 📜
- Log tree of settings at start
- Shoutrrr debug logs
- "IPv6 is not supported on this system" logged if all IP fetching tries fail with an IPv6 error
- Reduce log spamming: log each IP fetching error at the debug level and log them all at the error level in a single line, if all the fetching tries fail.
LISTENING_ADDRESS
configuration key (#590) to replaceLISTENING_PORT
(retro-compatible change) 👂- Docker images tags are now with and without the
v
prefix. For example:v2.6.0
and:2.6.0
🤷 internal/config
: append:53
to the resolver address if no port is given- More exact times for state updates, events and ban time checking 🕙
Fixes
- Core updating mechanism
- Get database events by IP version (#514)
- Skip update if public IP is not found
- Do not save invalid IP if the public IP is not found
- Set initial fail status if the public ip fetching failed
- Public IP fetching
- IPv6: replace bad regex with custom IPv6 extract function, affects allinkl, dnsomatic, google, he and noip
- Remove plaintext HTTP option
noip
- over HTTPs:
- use address of Cloudflare for "ipv4 or ipv6"
- remove opendns option
- over DNS: add opendns option
- Provider specific fixes
- Desec:
- default host to "@" if empty
- allow wildcard hosts
- DNSOMatic:
- remove username validation regex
- treat 'all' host as proxied to reduce updates, and does the IP comparison using the last IP stored in updates.json.
- DonDominio: update code to use newer
https://dondns.dondominio.com/json
endpoint - DuckDNS:
- send ip address if
"provider_ip": false
- support for IPv6 (#542)
- send ip address if
- Dyn: always give
myip=
parameter,provider_ip
setting disabled - Dynv6: set url ip field as 'auto' when
"provider_ip": true
(#549) - DynDNS: allow wildcard hosts
- Gandi: personal access token support (#568)
- Google: removed since no longer functional
- Infomaniak: handle new response prefixes
- Inwx: fix success codes detection
- Njalla: do not compare ip received when using
"provider_ip": true
- Noip: do not check for received IP when using
"provider_ip": true
- OpenDNS: IP received comparison check fixed
- Porkbun: delete ALIAS record before creating an A or AAAA record
- Spdyn: validate the host field value even if the token is set
- Desec:
- Web UI
- Bump HTTP timeout from 10s to 20s due to slow NoIP servers
- Logging:
- correct IP version for the "ipv4 no lookup" log line
- IPv4 only and IPv6 only debug logging (#513)
- Creation date set correctly by CI
- Settings:
- Ignore echo services absent from
PUBLICIP_FETCHERS
- Web UI listening port validation:
- Check start of unprivileged ports on Linux
- Check if running program has bind capability on Linux
- Ignore echo services absent from
Documentation
- Readme:
- Fix documentation for
SHOUTRRR_DEFAULT_TITLE
- Fix all dead links
- Fix shoutrrr bad link (#609)
- Remove outdated
ddnss
http public ip fetching - Use relative links, now compatible with Docker Hub description sync job
- Fix documentation for
docs/
directory:- fix all dead links
- cloudflare: wildcard hosts are allowed
- gcp: fix typo for provider name (#465)
- dnsomatic: fix settings fields (#463)
- infomaniak: add missing
username
field in example (#467) - opendns: fix bad provider name
dyn
toopendns
in example (#470) - noip: add missing
username
field in example (#469) - inwx:
- fix bad provider name
opendns
->inwx
(#468) - remove trail comma in JSON example
- fix bad provider name
- add missing
provider_ip
field in examples (#466) - add missing
ip_version
parameter for allinkl, name.com, netcup and porkbun - update
ip_version
description for all providers - nowdns:
- add missing
ip_version
parameter - remove trail comma in JSON example
- add missing
- Add Kubernetes examples & documentation (#402)
- Github:
- Update all labels
- More explicit title requirement in issue templates
- Remove automated @qdm12 assignee
- Fix typos (#532)
Maintenance
CI
- Add markdown workflow
- Remove docker hub description workflow
- Build workflow ignores md files for spellcheck
- Add goreleaser steps to build and attach binaries on release
- Bump linter
golangci-lint
from v1.52.2 to v1.55.2 - Add mocks check step
- Force matching Shoutrrr link with go.mod shoutrrr version (#491)
- Add dependabot configuration
- Add build-skip workflow for required workflows
- Bump github/codeql-action from 2 to 3 (#583)
- Bump docker/setup-buildx-action from 2 to 3 (#587)
- Bump docker/metadata-action from 4 to 5 (#585)
- Bump docker/build-push-action from 4.0.0 to 5.1.0 (#582)
Dependencies
- Remove dependency on
golang.org/x/net
- Bump breml/rootcerts from v0.2.11 to v0.2.14
- Bump github.com/miekg/dns from v1.1.42 to v1.1.57
- Bump golang.org/x/net from v0.1.0 to v0.17.0 (#540)
- Bump chi from v1.5.4 to v5.0.11
- Bump Go from 1.20 to 1.21
- Bump Alpine from 3.18 to 3.19
- Bump google.golang.org/grpc from 1.50.1 to 1.56.3 (#552)
- Bump github.com/stretchr/testify from v1.8.1 to v1.8.4
- Bump golang.org/x/mod from v0.12.0 to v0.14.0
Code
- Dockerfile:
- Remove outdated
SHOUTRRR_DEFAULT_TITLE
- Add
HEALTH_SERVER_ADDRESS=127.0.0.1:9999
- Remove outdated
- Migrate from
net.IP*
tonet/netip.Addr
andnet/netip.Prefix
- Drop
github.com/qdm12/golibs
dependencyinternal/persistence/json
: drop dependency on golibspkg/publicip/info
: remove dependency on golibscmd/updater
: replace golibs/connectivity withinternal/health
'sCheckHTTP
functioninternal/settings
: remove dependency onqdm12/golibs/verification
- Configuration reading reworked to use
qdm12/[email protected]
pkg/publicip/dns
: set dial timeout as the value of the parent fetcher timeout- Namecheap: make code only IPv4 compatible
- Servercow: use injected domain instead of re-decoding it from JSON
internal/update
:- simplify shouldUpdateRecord functions
shouldUpdateRecordNoLookup
andshouldUpdateRecordWithLookup
- simplify log calls
- rename run.go to service.go
- simplify shouldUpdateRecord functions
persistence/json
:- simplify
StoreNewIP
method - improve data check error messages
- simplify
internal/data
: remove unusedGetEvents
methodinternal/models
: remove unneededHTML
string alias type- OVH: remove unneeded sentinel errors
internal/provider/providers
:- replace ip nil check with
useProviderIP
check (affects duckdns, infomaniak and namecheap) - review HTTP headers: add missing header(s), remove unneeded headers
- review error wrappings for
client.Do
and wrap using stringdoing http request
- review error wrappings for validation errors
- Use
errors.BadRequest
forbadrequest
responses only - Change HTTP request creation error wrappings to be a string only
- Add missing HTTP request creation error wrappings
- remove intermediary errors and wrap them with strings instead of other sentinel errors
- replace ip nil check with
internal/provider/errors
: review update errors and wrappingsErrBadHTTPStatus
->ErrHTTPStatusNotValid
ErrNumberOfResultsReceived
->ErrResultsCountReceived
ErrNoResultReceived
->ErrReceivedNoResult
ErrAbuse
->ErrBannedAbuse
ErrInvalidSystemParam
->ErrSystemParamNotValid
ErrNoIPInResponse
->ErrReceivedNoIP
ErrUnsuccessfulResponse
->ErrUnsuccessful
- Remove
ErrRequestEncode
andErrRequestMarshal
and wrap errors with string instead - Remove
ErrUnmarshalResponse
and wrap errors with string instead - Add
ErrResponseTooShort
- RemoveErrNotFound
and replace with more precise not found errors - Add
ErrRecordResourceSetNotFound
error - Sort errors list alphabetically
- Change
Empty
->NotSet
- Change
Malformed
->NotValid
internal/shoutrrr
new package- .gitignore: fix
/data
path
Note: re-released as v2.6.0 to have permissions fixed for goreleaser to work (c338c28)
v2.5.0
Features
- 🆕 providers
- Shoutrrr library update to
v0.7.0
- Cloudflare: create record if it does not exist (#477)
- DNSPod: log entire JSON response on error
- Dreamhost: allow to specify a custom
host
- Specify resolver address with the
RESOLVER_ADDRESS
environment variable - Specify resolver timeout with the
RESOLVER_TIMEOUT
environment variable - Retry getting IP address up to 3 times
- Use
github.com/breml/rootcerts
v0.2.11 for TLS certs - Add destination to notification errors
- Add GHCR registry image (#259)
pkg/publicip/info
package (#189)pkg/publicip
: do not use providers banning us
Fixes
- Cloudflare:
key
->userServiceKey
variable name (#462)- fix service key regex
- dd24:
- API call and fix (#236)
- Handle non-empty responses
- ddnss.de add
dual_stack
parameter (#270, thanks @quantum-byte) - DNSOMatic:
- allow email addresses as
user
field - remove password regex check
- allow email addresses as
- DNSPod add IPv6 record ID finder
- FreeDNS fix
no ip change
messages decoding - Linode fix error decoding and set
name
field when creating record - LuaDNS match configured host instead of first record (#249)
- Namecheap XML decoding error & allow empty IP field in response
- OVH:
- fix signature in api mode
- support
nochg
responses
- Spdyn response handling for
good
andnochg
SHOUTRRR_ADDRESSES
case sensitivity fixed- Write JSON file from CONFIG variable
- DNS public IP fetching timeout fixed
- Better error messages for JSON decoding errors
- Shoutrrr validation error wrapping
Maintenance
- Fix line endings to lf (#220)
- Remove microbadger which went EOL
- Remove unneeded
/tmp/data
directory in Dockerfile - Use
github.com/qdm12/gosplash
for program start log information - Update
.devcontainer
definition files and readme
Code health
- General refactoring involving:
- Return concrete structs instead of interfaces
- Accept locally defined interfaces as narrow as possible
- Export returned struct types from exported functions
- Do not export interfaces for other packages to use
- Define and use sentinel errors
- Wrap all sentinel errors
- Use string comparisons instead of length for string variables
- Remove short if error checks
- Interface composition for Database
- HTTP client logger middleware
internal/backup
package refactorinternal/health
: remove unneededlogger
argument from functionsinternal/settings/*
: validate using local regexesinternal/settings/dyn
: change JSON field tag frompassword
toclient_key
(with retro-compatibility)internal/settings/providers/dyn
: more information on bad request errorinternal/settings/providers/ovh
: Add error context to errorsinternal/settings/providers
: rework IP string search code- Change database id to be
uint
instead ofint
- Remove
GetAllDomainsHosts
database method - Return
string
instead oferror
when appropriate (linode)
Linting
- Upgrade golangci-lint from v1.41.1 to v1.52.2
- Enable all default linters
- Add linters and fix new errors:
ireturn
,revive
,asasalint
,bidichk
,containedctx
,cyclop
,decorder
,durationcheck
,errchkjson
,errname
,errorlint
,execinquery
,forcetypeassert
,gomoddirectives
,grouper
,interfacebloat
,maintidx
,makezero
,nilnil
,nosprintfhostport
,promlinter
,reassign
,tenv
,usestdlibvars
,goerr113
,dupword
.paralleltest
,musttag
,gocheckcompilerdirectives
- Remove deprecated linters:
deadcode
,structcheck
andvarcheck
- Update exclude rules
Build
- Upgrade Go from 1.16 to 1.20
- Remove unneeded alpine
tzdata
package - Upgraded Alpine from 3.13 to 3.18
CI
- Allow slash in branch name for docker image tags (#219)
- Remove go modules tidy check
- Add UID and GID build arguments
- Bump GitHub actions versions (#353)
- Restrict publish image trigger events
Dependencies
- Use
github.com/qdm12/log
instead of logger fromgithub.com/qdm12/golibs
- Upgrade
qdm12/goshutdown
from v0.1.0 to v0.3.0 - Upgrade
github.com/qdm12/golibs
- Wrap errors in config package with environment variable name
- Update logger
Documentation
- Fix links in
.github/CONTRIBUTING.md
Readme
- Document
RESOLVER_ADDRESS
environment variable - Add Build the image section
- Clarify how to use another user ID for the container
- Rework metadata badges
- Fix lint errors
- Remove
sanitize
query parameter from svg tag - Autoformat document
./docs
v2.4.1
v2.4.0
Features
- Support for domaindiscount24.com (#207)
- Support Shoutrrr addresses
PUBLICIP_DNS_TIMEOUT
variable
Bug fixes
- Wildcard hosts (#214)
- Keep multi-dots wildcard host structure in display strings
- Use a function
BuildURLQueryHostname
for API calls to send the correct wildcard hostname - Send the wildcard character in API calls
- Fix behavior for wildcard hosts for: cloudflare, ddnss.de, digitalocean, dnsomatic, dreamhost, dyn, dynv6, google, informaniak, njalla, noip, opendns, ovh, selfhost.de, spdyn, strato and variomedia
- Healthcheck query to
127.0.0.1:port
instead of for example0.0.0.0:port
DATADIR
defaults to/updater/data
- Server listens on all interfaces (IPv4 and IPv6) instead of just
0.0.0.0
- Context dependent DNS resolutions (to exit the program promptly)
- Larger default timeout of 3s for DNS query of public IP
Documentation
- Add missing architectures to readme:
ppc64le
,s390x
,riscv64
andarmv6
Maintenance
internal/config
package for environment variables- Remove
github.com/ovh/go-ovh
dependency - Use
time/tzdata
anonymous import instead of Alpine'stzdata
- Use
github.com/qdm12/goshutdown
to handle program shutdown - Simplify file paths logic
- Use
signal.NotifyContext
(introduced with Go 1.16) - Inject more objects to
_main()
in main.go:params.Env
os.Args
- a default parent logger
- More robust main logic
- Change
main()
to encapsulate_main()
and handle OS signals itself _main()
returns an error instead of an exit code
- Change
- Move
setupGotify
inline in_main()
function - Local scoped
buildInfo
variable - Optimize Dockerfile for faster rebuilds, better layer caching and faster cross-builds
- Pull
xcputranslate
for build platform only (faster x-builds) - Install
golangci-lint
from qmcgaw/binpot (faster) - Install
g++
in base stage (for caching) - Copy
xcputranslate
in base stage (for caching) - Install
golangci-lint
in base stage (for caching) - Push
ARG TARGETPLATFORM
down in build stage (faster x-builds) - Push versioning
ARG
s andLABEL
down in final stage (for caching) - Move data directory
COPY
up in final stage (for caching)
- Pull
- Upgrade
golangci-lint
tov1.41.1
- Upgrade
qmcgaw/xcputranslate
tov0.6.0
- Set Docker test stage entrypoint in Dockerfile instead of CI