mirror of
https://github.com/TeaOSLab/EdgeCommon.git
synced 2026-03-18 12:45:53 +08:00
优化代码
This commit is contained in:
22
pkg/dnsconfigs/ns_recursion_config.go
Normal file
22
pkg/dnsconfigs/ns_recursion_config.go
Normal file
@@ -0,0 +1,22 @@
|
||||
// Copyright 2021 Liuxiangchao iwind.liu@gmail.com. All rights reserved.
|
||||
|
||||
package dnsconfigs
|
||||
|
||||
type NSDNSHost struct {
|
||||
Host string `json:"host"`
|
||||
Port int `json:"port"`
|
||||
Protocol string `json:"protocol"`
|
||||
}
|
||||
|
||||
// NSRecursionConfig 递归DNS设置
|
||||
type NSRecursionConfig struct {
|
||||
IsOn bool `json:"isOn"`
|
||||
Hosts []*NSDNSHost `json:"hosts"`
|
||||
UseLocalHosts bool `json:"useLocalHosts"` // 自动从本机读取DNS
|
||||
AllowDomains []string `json:"allowDomains"`
|
||||
DenyDomains []string `json:"denyDomains"`
|
||||
}
|
||||
|
||||
func (this *NSRecursionConfig) Init() error {
|
||||
return nil
|
||||
}
|
||||
Reference in New Issue
Block a user