mirror of
https://github.com/2dust/v2rayN.git
synced 2026-03-12 19:33:01 +00:00
Bug fix
Some checks are pending
release Linux / build (Release) (push) Waiting to run
release Linux / rpm (push) Blocked by required conditions
release macOS / build (Release) (push) Waiting to run
release Windows desktop (Avalonia UI) / build (Release) (push) Waiting to run
release Windows / build (Release) (push) Waiting to run
Some checks are pending
release Linux / build (Release) (push) Waiting to run
release Linux / rpm (push) Blocked by required conditions
release macOS / build (Release) (push) Waiting to run
release Windows desktop (Avalonia UI) / build (Release) (push) Waiting to run
release Windows / build (Release) (push) Waiting to run
https://github.com/2dust/v2rayN/issues/8879
This commit is contained in:
parent
f24a79aa2c
commit
4d2f32099e
1 changed files with 11 additions and 11 deletions
|
|
@ -301,6 +301,7 @@ public partial class CoreConfigV2rayService(CoreConfigContext context)
|
||||||
GenLog();
|
GenLog();
|
||||||
_coreConfig.outbounds.Clear();
|
_coreConfig.outbounds.Clear();
|
||||||
GenOutbounds();
|
GenOutbounds();
|
||||||
|
GenStatistic();
|
||||||
|
|
||||||
var protectNode = new ProfileItem()
|
var protectNode = new ProfileItem()
|
||||||
{
|
{
|
||||||
|
|
@ -326,18 +327,17 @@ public partial class CoreConfigV2rayService(CoreConfigContext context)
|
||||||
Node = protectNode,
|
Node = protectNode,
|
||||||
}).BuildProxyOutbound("tun-project-ss"));
|
}).BuildProxyOutbound("tun-project-ss"));
|
||||||
|
|
||||||
|
_coreConfig.routing.rules ??= [];
|
||||||
var hasBalancer = _coreConfig.routing.balancers is { Count: > 0 };
|
var hasBalancer = _coreConfig.routing.balancers is { Count: > 0 };
|
||||||
_coreConfig.routing.rules =
|
_coreConfig.routing.rules.Add(new()
|
||||||
[
|
{
|
||||||
new()
|
inboundTag = ["proxy-relay-ss"],
|
||||||
{
|
outboundTag = hasBalancer ? null : Global.ProxyTag,
|
||||||
inboundTag = new List<string> { "proxy-relay-ss" },
|
balancerTag = hasBalancer ? Global.ProxyTag + Global.BalancerTagSuffix : null,
|
||||||
outboundTag = hasBalancer ? null : Global.ProxyTag,
|
type = "field"
|
||||||
balancerTag = hasBalancer ? Global.ProxyTag + Global.BalancerTagSuffix: null,
|
});
|
||||||
type = "field"
|
|
||||||
}
|
//_coreConfig.inbounds.Clear();
|
||||||
];
|
|
||||||
_coreConfig.inbounds.Clear();
|
|
||||||
|
|
||||||
var configNode = JsonUtils.ParseJson(JsonUtils.Serialize(_coreConfig))!;
|
var configNode = JsonUtils.ParseJson(JsonUtils.Serialize(_coreConfig))!;
|
||||||
configNode["inbounds"]!.AsArray().Add(new
|
configNode["inbounds"]!.AsArray().Add(new
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue