-
Notifications
You must be signed in to change notification settings - Fork 3
/
smartdns.conf
45 lines (35 loc) · 1.16 KB
/
smartdns.conf
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
# 服务
server-name smartdns
bind-tcp [::]:10053
bind [::]:10053
# 日志
log-level info
log-file /var/log/smartdns/smartdns.log
log-size 50m
# DNS缓存
cache-size 5120
rr-ttl-min 600
rr-ttl-max 3600
prefetch-domain yes
cache-file /tmp/smartdns.cache
# 测速
response-mode first-ping
speed-check-mode ping,tcp:80,tcp:443
# 扩展功能
force-AAAA-SOA no
mdns-lookup yes
# 上游 UDP DNS private
server 211.139.5.29 -group private
server 223.5.5.5 -group private
server 119.29.29.29 -group private
# 上游 UDP DNS public
server-https https://dns.google/dns-query -group public -exclude-default-group
server-https https://cloudflare-dns.com/dns-query -group public -exclude-default-group
# 加载HOSTS本地文件
hosts-file /etc/smartdns/hosts.conf
# 加载国际分组解析文件
domain-set -name proxy-domain-list -type list -file /etc/smartdns/proxy-domain-list.conf
domain-rules /domain-set:proxy-domain-list/ -nameserver public -speed-check-mode none -address #6 -no-cache
# 加载国内分组解析文件
# domain-set -name direct-domain-list -file /etc/smartdns/direct-domain-list.conf
# domain-rules /domain-set:direct-domain-list/ -nameserver private