render zone file
This block is part of the dns group and was last modified in core v15.0.0.
render zone file v15.0.0 Render a complete BIND zone file from stored records, with the decision report that belongs in front of a push.
- flow
flow - Zone required
valueThe origin being rendered, for example deverence.nl.
- Records required
arrayThe records, as the store holds them. For a group member, the group's record set.
- SOA required
objectThis apex's own SOA timers: mname, rname, refresh, retry, expire, minimum.
- Nameservers
arrayThis apex's own existing NS set. Ours are added alongside.
- Group base zone
valueSet this to render a group member: the records are the group's and belong to this base apex.
- Rules
arrayThe group's policy: {action, owner, type, value_contains, slot, why}. First match wins.
- Own records
arrayThis member's own versions of the per-apex records, each carrying the slot it fills.
- Extra records
arrayRecords that exist only on this apex and have no counterpart in the base.
- Slots not applicable
objectSlot name to the reason this domain will never fill it. A recorded decision reads differently from a gap.
- Strict
conditionRefuse the render outright when a per-apex slot is neither filled nor explained.
- Flatten out-of-zone ALIAS
conditionResolve ALIAS targets outside this zone to addresses. They go stale when the target moves, so every one is reported with the time it was resolved. In-zone targets never need this.
- Allow routing policies
conditionEmit routing-policy records commented out instead of refusing.
- Serial
numberStamp this serial instead of the epoch at render time.
- Our nameservers
valueComma-separated. The default is a placeholder (ns1.example.com, ns2.example.com, ns3.example.com) : set your own authoritative nameservers.
- Header
valueComment lines above the origin. Each line is prefixed with a semicolon if it has none.
- Negative TTL
numberSeconds a resolver may cache 'this name does not exist'. Written BOTH as the SOA's own TTL and as its MINIMUM field, because RFC 2308 caches a negative answer for the lower of the two : setting MINIMUM alone does nothing while the SOA inherits a smaller $TTL. Default 900.
- flow
flow - Success
conditionTrue when the zone rendered.
- Zone
valueThe origin, without its trailing dot.
- Zone file
valueThe complete zone file, ready to check and push.
- Serial
numberThe serial stamped into the file.
- Records
arrayThe effective record set : for a group member, the composed one.
- Count
numberHow many record sets the zone carries.
- Report
objectEvery decision the render made: rewritten, noted, flattened and refused. Show this before a push is confirmed.
- Aliases
arrayEvery ALIAS, with its scope, what it resolved to and : out of zone : when.
- Slots
arrayPer-apex slots, each with state filled, not-applicable or empty.
- Unfilled slots
arraySlots nobody has answered for. A zone with any of these must not be pushed.
- Complete
conditionTrue when every per-apex slot is filled or explained. Wire this into the push.
- Error
valueWhy the render was refused.
Renders stored records into a complete BIND zone file on zone_file. PURE: no network, no server, no writes : same store state, same bytes apart from the serial. That separation is what makes a resync a re-render instead of a diff-repair, and what lets the UI show exactly what will land before anything does. ONE BLOCK, TWO SHAPES. Given records alone, it renders that zone. Given base_zone as well, the records are a zone GROUP's and this apex is a member: group semantics run first and the composed set comes back on the records pin. In a group, each value takes the first matching entry in rules ({action, owner, type, value_contains, slot, why}; a missing field is a wildcard), falling back to the record's own policy : 'verbatim' (default), 'rewrite' (re-aim a target naming the base apex at this member's, REFUSING if it changed nothing), 'per-apex' (drop the base value; the record becomes a slot this member fills from its own records) or 'note' (copy but flag). overrides are this member's own slot fills, extra are records existing only on this apex, slots_na is {slot: reason}. A slot neither filled nor in slots_na is EMPTY: complete comes back false and, with strict on, the render is refused. ALIAS has no BIND equivalent and the two cases differ completely. An IN-ZONE target (deverence.com -> www.deverence.com) is answered from the zone's OWN RECORDS: deterministic, no resolver, never stale, and it REFUSES if the target names nothing in the zone rather than emitting a record that is silently missing. An OUT-OF-ZONE target (an ELB, a CloudFront name) needs a live lookup, so it requires flatten_alias and comes back with a resolved_at timestamp, because it goes stale when the target moves. The apex NS set becomes the zone's existing nameservers PLUS our_nameservers (default the canonical trio). The serial is the epoch at render time unless a serial is passed.
render zone |
zone file |
render group member |
dupping |
A typical wiring for render zone file: a function trigger starts the flow; value feeds the zone pin; with values feeds the records pin; new object feeds the soa pin; the flow out pin feeds debug.
Used in these guides
These documentation pages use or explain this block:
Version history
Introduced in v15.0.0.
Back to
dns Return to the main group to view all sub-groups Back to DNS zones Return to the group to view all blocks within this group 