请问以下配置文件可以简化一下吗? #3162
请问以下配置文件可以简化一下吗?
#3162
Replies: 1 comment
-
{
"outbounds": [
{
"tag": "ip"
},
{
"tag": "ipv4",
"domainStrategy": "UseIPv4" // 出站的这参数,如果你不写,默认行为是AsIs。你写了,工作流程进进到出站的请求是域名,这域名进Xray的DNS部分,如果你没写DNS就是用系统DNS查询
}
],
"routing": {
"rules": [
{
"type": "field",
"domain": [
"bing.com",
"gemini.google.com"
],
"outboundTag": "ipv4"
}
]
}
} |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
lindongbin
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
{
"outbounds": [
{
"tag":"ip"
},
{
"tag":"ipv4",
"domainStrategy": "UseIPv4"
}
],
"routing":{
"rules":[
{
"type": "field",
"domain": [
"bing.com",
"gemini.google.com"
],
"outboundTag": "ipv4"
}
]
}
}
outbounds tag ip 和 ipv4的唯一区别是多了个"domainStrategy": "UseIPv4",其它都是一样的,然后bing.com和gemini.google.com走ipv4这个tag,因为如果不添加"domainStrategy": "UseIPv4",bing.com会自动跳CN,gemini.google.com会提示不支持所在地区,配置 文件看起来有点长了,不知道能不能简化一下,"domainStrategy": "UseIPv4"这个可以在其它位置判断吗?
Beta Was this translation helpful? Give feedback.
All reactions