家庭内网使用 adguardhome 解析私有域名 192.168 这些 但是当我出门后
1
clickhouse 277 天前
为什么不直接将域名解析到 192.168 呢,是不想将解析记录放在公网?
|
2
orluna OP @clickhouse 好有道理哦,很直接有效的方法。常规的做法就是这样的吗
|
3
clickhouse 277 天前
@orluna 我也不知道答案,只知道有很多大厂有 127 的解析记录,例如:localhost.ptlogin2.qq.com
|
4
lan894734188 277 天前
wg 可以添加 dns 配置指定 dns
|
5
yuchenr 277 天前
wireguard 可以指定 dns 的,
另外,为什么不直接用 wireguard 回家? |
6
PerFectTime 277 天前 via iPhone
1.编辑 surge 配置,这个域名下所有的 dns 会被 1.1 接管
[Host] *.example.com = server:192.168.1.1 2.要么写 host ,要么 dns 走你家 adguard home ,要么公网留存解析记录 |
7
noahzh 277 天前
就直接走公网 dns 就完了,反正都是内网地址不用怕,因为各种代理在 dns 上处理上会有些不同,省的给自己找麻烦.
|
8
orluna 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 ``` 但是内网 可以成功解析出来 问题可能出在哪里 |
10
yuchenr 277 天前
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) |
11
orluna OP 成功了还需要加一条规则
DOMAIN-SUFFIX,域名 wireguard-home |
12
yyysuo 276 天前
收藏夹就好了,域名有什么用,难道你们每次还要输入域名吗?
|
13
sbilly 238 天前
本机保持 wg 和家里连接,确保 wg 可以连接到家里 adguardhome ,本机 dns 指向家里 adguardhome 就可以了
|