2013-07-23 11:10:38 +00:00
|
|
|
#Toml config file
|
2020-01-25 18:48:26 +00:00
|
|
|
debug = false
|
2013-07-23 11:10:38 +00:00
|
|
|
|
|
|
|
[server]
|
2018-08-05 01:53:31 +00:00
|
|
|
host = "0.0.0.0"
|
2020-01-25 17:43:02 +00:00
|
|
|
nets = ["tcp:53", "udp:53"]
|
2013-07-23 11:10:38 +00:00
|
|
|
|
|
|
|
[resolv]
|
2020-01-25 18:48:26 +00:00
|
|
|
file = ""
|
2013-07-24 02:52:59 +00:00
|
|
|
timeout = 5 # 5 seconds
|
2015-05-07 09:58:31 +00:00
|
|
|
interval = 200 # 200 milliseconds
|
2020-01-25 18:48:26 +00:00
|
|
|
edns0 = false #Support for larger UDP DNS responses
|
|
|
|
# Domain-specific nameservers configuration, formatting keep compatible with Dnsmasq
|
|
|
|
server-list = "etc/serverlist.conf"
|
2016-02-12 13:29:25 +00:00
|
|
|
|
2013-07-23 11:10:38 +00:00
|
|
|
[log]
|
2015-10-13 11:35:29 +00:00
|
|
|
stdout = true
|
|
|
|
file = "./godns.log"
|
2018-08-05 08:48:26 +00:00
|
|
|
level = "DEBUG" #DEBUG | INFO |NOTICE | WARN | ERROR
|
2015-10-13 11:35:29 +00:00
|
|
|
|
2013-07-23 11:10:38 +00:00
|
|
|
[cache]
|
2020-01-25 18:48:26 +00:00
|
|
|
# backend option [memory|memcache|redis]
|
|
|
|
backend = "memory"
|
2013-07-23 11:10:38 +00:00
|
|
|
expire = 600 # 10 minutes
|
2013-07-29 09:30:10 +00:00
|
|
|
maxcount = 0 #If set zero. The Sum of cache itmes will be unlimit.
|
2013-07-26 04:06:16 +00:00
|
|
|
|
2020-01-25 18:48:26 +00:00
|
|
|
[cache.memcached]
|
|
|
|
servers = ["127.0.0.1:11211"]
|
2016-09-18 04:04:21 +00:00
|
|
|
|
2020-01-25 18:48:26 +00:00
|
|
|
# Redis cache backend config
|
|
|
|
[cache.redis]
|
2020-02-08 03:38:22 +00:00
|
|
|
host = "127.0.0.1"
|
2020-01-25 18:48:26 +00:00
|
|
|
port = 6379
|
|
|
|
db = 0
|
|
|
|
password =""
|
2013-07-26 04:06:16 +00:00
|
|
|
|
2020-01-25 18:48:26 +00:00
|
|
|
[hosts]
|
|
|
|
# File provider, supports inotify hot-reload
|
|
|
|
[hosts.file]
|
|
|
|
enable = true
|
|
|
|
file = "/etc/hosts"
|
|
|
|
ttl = 600
|
|
|
|
|
|
|
|
# Redis provider
|
|
|
|
[hosts.redis]
|
|
|
|
enable = true
|
|
|
|
key = "godns:hosts"
|
|
|
|
ttl = 600
|