{ config, lib, pkgs, ... }: with lib; let mkSrvRecord = host: port: { inherit host port; }; instantiateZone = zoneName: { primaryNameserver, secondaryNameservers ? [ ], externalNameservers ? [ ] , smtpServers, imapServers, ... }: { gssapi-realm = gssapiRealm; mx = smtpServers; dmarc-report-address = "dmarc-report@${zoneName}"; default-host = defaultHost; verbatim-dns-records = mkIf (ksk != null) [ ksk.public-key-record ksk.ds ]; }; in { inherit instantiateZone; }