diff options
| author | Shulhan <m.shulhan@gmail.com> | 2019-10-16 21:41:27 +0700 |
|---|---|---|
| committer | Shulhan <m.shulhan@gmail.com> | 2019-10-16 21:49:20 +0700 |
| commit | 711e75f2b58a44b51b4c7a2b47a341c29a5e675a (patch) | |
| tree | 260142d7b71cd24450260443ae94dfe60ca14177 /testdata | |
| parent | e1366b601bf8e74b21918fe9121b1e3e30d73b1b (diff) | |
| download | rescached-711e75f2b58a44b51b4c7a2b47a341c29a5e675a.tar.xz | |
all: refactoring configuration file
The configuration file now group into two section: the '[rescached]' and
'[dns "server"]' sections. All of the configuration values are loaded
using ini.Unmarshal instead of using manual parsing.
Diffstat (limited to 'testdata')
| -rw-r--r-- | testdata/rescached.cfg | 39 |
1 files changed, 11 insertions, 28 deletions
diff --git a/testdata/rescached.cfg b/testdata/rescached.cfg index 83676a4..41a786b 100644 --- a/testdata/rescached.cfg +++ b/testdata/rescached.cfg @@ -1,46 +1,29 @@ -[RESCACHED] +[rescached] + +[dns "server"] ## -## server.parent:: List of parent DNS servers, separated by commas. +## parent:: List of parent DNS servers, separated by commas. ## ## Format:: <IP-ADDRESS:PORT> , ... -## Default address:: 1.1.1.1, 1.0.0.1 +## Default address:: 35.240.172.103 ## Default port:: 53 ## -#server.parent=1.1.1.1, 1.0.0.1:53 - -## -## server.parent.connection:: Type of connection to parent server. -## -## Format:: tcp | udp -## Default:: udp -## - -server.parent.connection=udp -#server.parent.connection=tcp +#parent=35.240.172.103 ## -## server.listen:: Local IP address that rescached will listening for client +## listen:: Local IP address that rescached will listening for client ## request. ## ## Format:: <IP-ADDRESS>:<PORT> ## Default:: 127.0.0.1:53 ## -server.listen=127.0.0.1:5353 +listen=127.0.0.1:5353 ## Uncomment line below if you want to serve rescached to other computers. -#server.listen=0.0.0.0:53 - -## -## server.timeout:: Timeout value, in seconds, for sending and waiting -## packet from client or parent server. -## Format:: any number from 300 to 2147483647. -## Default:: 6 -## - -#server.timeout=6 +#listen=0.0.0.0:53 ## ## cache.prune_delay:: Delay for pruning worker. @@ -63,14 +46,14 @@ server.listen=127.0.0.1:5353 #cache.threshold = -1h ## -## hosts_d.path:: If its set, rescached will load all (host) files in path. +## dir.hosts:: If its set, rescached will load all (host) files in path. ## if its empty, it will skip loading hosts files event in default location. ## ## Format : string. ## Default : /etc/rescached/hosts.d ## -#hosts_d.path=/etc/rescached/hosts.d +#dir.hosts=/etc/rescached/hosts.d ## ## debug:: If its not zero, rescached will print debugging information to |
