mirror of
https://github.com/Control-D-Inc/ctrld.git
synced 2026-07-04 01:07:49 +02:00
Use ControlD Public DNS when non-available
This logic was missed when new initializing OS resolver logic was implemented. While at it, also adding this test case to prevent regression.
This commit is contained in:
committed by
Cuong Manh Le
parent
a9f76322bd
commit
f5ba8be182
@@ -118,6 +118,9 @@ func initializeOsResolver(servers []string) []string {
|
||||
} else {
|
||||
or.lanServers.Store(&lanNss)
|
||||
}
|
||||
if len(publicNss) == 0 {
|
||||
publicNss = append(publicNss, controldPublicDnsWithPort)
|
||||
}
|
||||
or.publicServers.Store(&publicNss)
|
||||
return slices.Concat(lanNss, publicNss)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user