COREDNS-AUTO(7)
π¦ COREDNS-AUTO π¦
okay so bestie, this is the auto manual page from the CoreDNS plugins collection β and no cap, it's lowkey one of the most "set it and forget it" plugins out there π
β¨ NAME β¨
auto β it enables serving zone data from an RFC 1035-style master file, and the whole vibe is that this file gets automatically picked up from disk πΈ
π DESCRIPTION π
The auto plugin is your "old-style" DNS server era π It serves from a preloaded file that exists on disk β very main character, very reliable.
If the zone file contains signatures (i.e. it's signed, i.e. it's using DNSSEC), then correct DNSSEC answers are returned π«Ά But listen β only NSEC is supported! Not NSEC3, bestie, NSEC. If you go with this setup, you are the responsible one for re-signing the zonefile. That's your job, not the plugin's π
New or changed zones get automatically picked up from disk only when SOA's serial changes β And if the zones aren't being updated via a zone transfer, then the serial must be manually changed. Like, by hand. With your own hands. π
π SYNTAX π
auto [ZONES...] {
directory DIR [REGEXP ORIGIN_TEMPLATE]
reload DURATION
}
- ZONES β the zones it should be authoritative for π If it's empty, the zones from the configuration block are used instead.
directoryβ loads zones from the specified DIR π If a file name matches REGEXP, then that regex is used to extract the origin. ORIGIN_TEMPLATE gets used as a template for the origin. Strings like{<number>}are replaced with the respective matches in the file name β so{1}is the first match,{2}is the second, etc. β¨
The default is: db.(.*) {1} β meaning from a file named db.example.com, the extracted origin will be example.com. So cute, so convenient π
β οΈ REGEXP must not be longer than 10000 characters. That's the limit, bestie. Also REGEXP is unanchored π« so use^and$if you need the match to cover the full file name β for example^(.*).zone$to avoid matching backup files likeexample.org.zone.bak. Protect yourself π
reloadβ the interval for performing reloads of zones when the SOA version changes, and of zonefiles π It specifies how often CoreDNS should scan the directory to watch for file removal and addition. Default is one minute β° A value of0means don't scan for changes and don't reload, periodt. e.g.30schecks the zonefile every 30 seconds and reloads the zone when the serial changes π₯
For enabling zone transfers, go look at the transfer plugin π
All the directives from the file plugin are supported π Note that auto will load all the zones it finds, even though the directive might only receive queries for a specific zone. I.e:
. {
auto example.org {
directory /etc/coredns/zones
}
}
This will happily pick up a zone for example.COM β except it will never be queried, because the auto directive is only authoritative for example.ORG π slay, but also, oops.
π EXAMPLES π
Load org domains from /etc/coredns/zones/org and allow transfers to the internet, but send notifies to 10.240.1.1 π
org {
auto {
directory /etc/coredns/zones/org
}
transfer {
to *
to 10.240.1.1
}
}
Load org domains from /etc/coredns/zones/org and look for file names like www.db.example.org, where example.org is the origin. Scan every 45 seconds. β±οΈ
org {
auto {
directory /etc/coredns/zones/org www\.db\.(.*) {1}
reload 45s
}
}
π ALSO π
Use the root plugin to help you specify the location of the zone files ποΈ And see the transfer plugin to enable outgoing zone transfers π¦
okay that's the whole page bestie, you ate that π β¨
this little icon was brought to you by CoreDNS, October 2026, and the manual page COREDNS-AUTO(7) β go forth and serve those zones ππΈ
π¦ where this page comes from
- opensuse-leap 16.0: coredns-extras 1.15.0-bp160.1.1 Β· Apache-2.0 AND MPL-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms