update box

fix
This commit is contained in:
arm64v8a
2022-09-29 10:01:46 +08:00
parent 0b783d9130
commit 811be931cd
10 changed files with 85 additions and 45 deletions

View File

@@ -698,8 +698,8 @@ namespace NekoRay {
// geopath
auto geoip = FindCoreAsset("geoip.db");
auto geosite = FindCoreAsset("geosite.db");
if (geoip.isEmpty()) result->error = geoip + " not found";
if (geosite.isEmpty()) result->error = geosite + " not found";
if (geoip.isEmpty()) result->error = + "geoip.db not found";
if (geosite.isEmpty()) result->error = + "geosite.db not found";
// final add routing rule
QJSONARRAY_ADD(routingRules, QString2QJsonObject(dataStore->custom_route_global)["rules"].toArray())
@@ -711,6 +711,19 @@ namespace NekoRay {
{"geosite", QJsonObject{{"path", geosite},},}
});
// api
result->coreConfig.insert("experimental", QJsonObject{
{"v2ray_api", QJsonObject{
{"listen", "127.0.0.1:" + Int2String(dataStore->inbound_socks_port + 10)},
{"stats", QJsonObject{
{"enabled", true},
{"outbounds", QJsonArray{
tagProxy, "bypass", "block"
}},
}}
}},
});
return result;
}