define system config for dns resolver
This commit is contained in:
parent
f4ff592efd
commit
78a1b6daa7
4 changed files with 62 additions and 0 deletions
23
systems/resolv-dns.noc.eh22.intern/kresd-config.lua
Normal file
23
systems/resolv-dns.noc.eh22.intern/kresd-config.lua
Normal file
|
@ -0,0 +1,23 @@
|
|||
-- ref: https://www.knot-resolver.cz/documentation/stable/config-overview.html
|
||||
|
||||
-- load non-default modules
|
||||
modules.load("view")
|
||||
modules.load("prefill")
|
||||
|
||||
-- define list of internal-only domains
|
||||
ehDomains = policy.todnames({'noc.eh22.intern'})
|
||||
|
||||
-- for the mgmt-network, forward ehDomains to our authorative server
|
||||
view:addr('10.20.25.0/24', policy.suffix(policy.FLAGS({'NO_CACHE'}), ehDomains))
|
||||
view:addr('10.20.25.0/24', policy.suffix(policy.STUB({'10.20.25.3'}), ehDomains))
|
||||
|
||||
-- allow resolution from our internal network
|
||||
view:addr('10.20.25.0/24', policy.all(policy.PASS))
|
||||
|
||||
-- precache the root zone to reduce traffic load to it
|
||||
prefill.config({
|
||||
["."] = {
|
||||
url = "https://www.internic.net/domain/root.zone",
|
||||
interval = 24 * 60 * 60,
|
||||
}
|
||||
})
|
Loading…
Add table
Add a link
Reference in a new issue