add doh support

This commit is contained in:
iceBear67
2026-07-26 14:14:03 +08:00
parent 20097a02a1
commit 5dc1759d80
9 changed files with 335 additions and 32 deletions
+5
View File
@@ -28,6 +28,11 @@ func serviceLogic(configPath string, isTsnetDebug bool, configURL string, logger
os.Exit(1)
}
core.SetDoHServers(cfg.DNS.DoHServers)
if len(cfg.DNS.DoHServers) > 0 {
logger.Info("DNS-over-HTTPS fallback enabled", "servers", cfg.DNS.DoHServers)
}
ctx, cancelAll := context.WithCancel(context.Background())
defer cancelAll()
logger.Info("initializing tsnet server")