-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathexample.lua
More file actions
95 lines (93 loc) · 2.49 KB
/
example.lua
File metadata and controls
95 lines (93 loc) · 2.49 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
-- /etc/powerdns/pdns-recursor-scripts/conf.d/example.lua
-- Beware, this file gets directly included into the hooks.lua file
-- You can load multiple config files, repeated options will be replaced by the last file.
-- Recommended names: overrides.lua || settings.lua || conf_dnsbl.lua || conf_local.lua
return {
-- Local Domain Override Options
main_domain = "example.com",
use_one_to_one = false,
one_to_one_subnets = {
{
["source"]="127.0.0.0/16",
["target"]="127.1.0.0/16",
["acl"]={
"100.64.0.0/10",
},
-- Whether to break the loop as soon as this rule is matched
-- Default is true
["break_loop"]=true
}
},
internal_reverse_proxy_v4 = "YOUR_INTERNAL_WEB_REVERSE_PROXY",
internal_reverse_proxy_v6 = "YOUR_INTERNAL_WEB_REVERSE_PROXY",
use_local_forwarder = false,
exclude_main_domain_from_irp = true,
exclude_local_forwarder_domains = {
"external.example.com"
},
exclude_local_forwarder_domains_re = {
"^(sub1|sub2).example.com$"
},
-- Allow Overrides for Non-Local Domains
allow_non_local_overrides = false,
-- Exact matches have higher priority
override_map = {
{
name="static.example.com",
qtype="CNAME",
content={
"webserver.example.com"
},
external=false -- Implicit value
}
},
--[[
Regex matches are sequentially checked, so you should keep your higher
specificity patterns on top.
]]
regex_map = {
{
pattern="^(mail|smtp|imap|smtps|smtp)\\..*$",
qtype="CNAME",
content={
"mx.example.com"
},
external=false -- Implicit value
},
{
pattern="^(a-record)\\..*$",
qtype="A",
content={
"127.0.0.1"
},
external=false -- Implicit value
},
{
pattern="^(cname-record-1)\\..*$",
qtype="CNAME",
content={
"mail.example.com"
},
external=false -- Implicit value
},
{
pattern="^.*$",
qtype="NS",
content={"ns1.example.com","ns2.example.com"},
external=false -- Implicit value
},
},
default_ttl = 900,
-- For local cname chain resolution
cname_resolver_enabled = false,
-- Usually you won't need to change the address.
cname_resolver_address = "127.0.0.1",
-- Change this if your PowerDNS Recursor is on a non-standard port.
cname_resolver_port = 53,
-- Extra Debug Logging options
debug_pre_override = false,
debug_post_one_to_one = false,
-- Malware Filter Options
use_dnsbl = false, -- If you want to preresolve with DNSBL files (.list|.txt) in the dnsbl.d directory
use_ipbl = false, -- If you want to postresolve with IPBL files (.list|.txt) in the ipbl.d directory
}