mirror of
https://github.com/ipfs/kubo.git
synced 2026-02-21 10:27:46 +08:00
go-ipfs-config: add custom DNS Resolver configuration
This commit is contained in:
parent
2690c10bca
commit
8a8b161da4
@ -28,6 +28,7 @@ type Config struct {
|
||||
AutoNAT AutoNATConfig
|
||||
Pubsub PubsubConfig
|
||||
Peering Peering
|
||||
DNS DNSConfig
|
||||
|
||||
Provider Provider
|
||||
Reprovider Reprovider
|
||||
|
||||
10
config/dns.go
Normal file
10
config/dns.go
Normal file
@ -0,0 +1,10 @@
|
||||
package config
|
||||
|
||||
// DNSConfig specifies custom resolvers using DoH
|
||||
type DNSConfig struct {
|
||||
// DefaultResolver, if present, is a URL for the default DoH resolver.
|
||||
// If empty, DNS resolution will use the system resolver.
|
||||
DefaultResolver string `json:",omitempty"`
|
||||
// CustomResolvers is a map of domains to URLs for custom DoH resolution.
|
||||
CustomResolvers map[string]string `json:",omitempty"`
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user