家庭内网使用 adguardhome 解析私有域名 192.168 这些 但是当我出门后
|      1clickhouse      2023-07-25 20:52:50 +08:00 为什么不直接将域名解析到 192.168 呢,是不想将解析记录放在公网? | 
|      2orluna OP @clickhouse 好有道理哦,很直接有效的方法。常规的做法就是这样的吗 | 
|      3clickhouse      2023-07-25 20:59:52 +08:00 @orluna 我也不知道答案,只知道有很多大厂有 127 的解析记录,例如:localhost.ptlogin2.qq.com | 
|  |      4lan894734188      2023-07-25 21:58:31 +08:00 wg 可以添加 dns 配置指定 dns | 
|      5yuchenr      2023-07-26 08:00:37 +08:00 wireguard 可以指定 dns 的, 另外,为什么不直接用 wireguard 回家? | 
|      6PerFectTime      2023-07-26 08:25:55 +08:00 via iPhone 1.编辑 surge 配置,这个域名下所有的 dns 会被 1.1 接管 [Host] *.example.com = server:192.168.1.1 2.要么写 host ,要么 dns 走你家 adguard home ,要么公网留存解析记录 | 
|      7noahzh      2023-07-26 09:26:23 +08:00 就直接走公网 dns 就完了,反正都是内网地址不用怕,因为各种代理在 dns 上处理上会有些不同,省的给自己找麻烦. | 
|      8orluna OP 成功在 wireguard 上添加了配置 dns 服务器 ``` [Interface] DNS = 192.168.100.214 ``` 但是在公网 dns 解析 没有响应 ``` nslookup example.com Server: 192.168.100.214 Address: 192.168.100.214#53 Non-authoritative answer: *** Can't find w.ccw.es: No answer ``` 但是内网 可以成功解析出来 问题可能出在哪里 | 
|  |      9zer      2023-07-26 10:42:48 +08:00 @orluna 因为你用的是 Surge 连的 WG ,他的 DNS 应该不会走 WG 的隧道。如果用 WG 自己的客户端,就能让 DNS 走隧道。 | 
|      10yuchenr      2023-07-26 11:08:08 +08:00 https://manual.nssurge.com/policy/wireguard.html 可以给 WireGuard 设置 dns 的。 [Proxy] wireguard-home = wireguard, section-name = HomeServer [WireGuard HomeServer] private-key = sDEZLACT3zgNCS0CyClgcBC2eYROqYrwLT4wdtAJj3s= self-ip = 10.0.2.2 self-ip-v6 = fd00:1111::11 dns-server = 8.8.8.8, 2606:4700:4700::1001 prefer-ipv6 = false mtu = 1280 peer = (public-key = fWO8XS9/nwUQcqnkfBpKeqIqbzclQ6EKP20Pgvzwclg=, allowed-ips = 0.0.0.0/0, endpoint = 192.168.20.6:51820) | 
|      11orluna OP 成功了还需要加一条规则 DOMAIN-SUFFIX,域名 wireguard-home | 
|      12yyysuo      2023-07-27 08:38:45 +08:00 收藏夹就好了,域名有什么用,难道你们每次还要输入域名吗? | 
|  |      13sbilly      2023-09-03 15:23:06 +08:00 本机保持 wg 和家里连接,确保 wg 可以连接到家里 adguardhome ,本机 dns 指向家里 adguardhome 就可以了 |