mholt / caddy-dynamicdns

Caddy app that keeps your DNS records (A/AAAA) pointed at itself.
Apache License 2.0
236 stars 24 forks source link

domains: merge zones with the same name #45

Closed otaconix closed 1 year ago

otaconix commented 1 year ago

This PR is the result of a feature request I made over at https://github.com/lucaslorentz/caddy-docker-proxy/issues/487.

Basically, I want to be able to repeat zones in the domains block, so I can have the domains I want to dynamically update spread out over my container labels when using caddy-docker-proxy .

I made the simplest possible solution for this in this PR. I initially considered changing the App.Domains field to a list of some new struct, but decided not to do that to keep backwards compatibility in the JSON caddy config, and because the diff is smaller :slightly_smiling_face: