complete example

This commit is contained in:
Yuzuki616 2023-09-16 20:35:42 +08:00
parent 3a7d10c142
commit 1b3e173a8a
3 changed files with 242 additions and 110 deletions

View File

@ -1,142 +1,47 @@
{
"Log": {
// V2bX Core log
// info, warn, error, none
"Level": "error",
//
"Level": "info",
"Output": ""
},
"Cores": [
{
// Core
"Type": "sing",
// Core
"Name": "sing1",
"Log": {
// SingBox log
"Level": "error",
"Timestamp": true
},
"NTP": {
// SingBox ntp
// VMess VLESS
"Enable": true,
"Server": "time.apple.com",
"ServerPort": 0
}
// More
},
{
"Type": "sing",
"Name": "sing2",
"Log": {
"Level": "info",
"Timestamp": false
},
},
{
"Type": "xray",
"Log": {
// Xray-core log
"Level": "error"
},
"DnsConfigPath": ""
// More
}
],
"Nodes": [
// Node
{
// 1
// Node便
//
"Name": "sing_node1",
// 使Core
// CoreName
// CoreCoreName
"Core": "sing",
// 使Core
"CoreName": "sing1",
// API
"ApiHost": "http://127.0.0.1",
// APIToken
"ApiKey": "test",
// ID
"NodeID": 33,
//
"NodeType": "shadowsocks",
//
"Timeout": 30,
// IP
"ListenIP": "0.0.0.0",
// IP
"SendIP": "0.0.0.0",
// Proxy Protocol https://github.com/haproxy/haproxy/blob/master/doc/proxy-protocol.txt
"EnableProxyProtocol": false,
// TCP Fast Open
"EnableTFO": true,
// Domain Strategy
// prefer_ipv4 / prefer_ipv6 / ipv4_only / ipv6_only
"DomainStrategy": "ipv4_only"
// More
},
{
//
"Include": "../example/config_node1.json",
"DomainStrategy": "ipv4_only",
"LimitConfig": {
"EnableRealtime": false,
"SpeedLimit": 0,
"IPLimit": 0,
"ConnLimit": 0,
"EnableDynamicSpeedLimit": false,
"DynamicSpeedLimitConfig": {
"Periodic": 60,
"Traffic": 1000,
"SpeedLimit": 100,
"ExpireTime": 60
}
}
}
/*,
{
// 2
// ApiConfig
"ApiConfig": {
"ApiHost": "http://127.0.0.1",
"ApiKey": "test",
"NodeID": 33,
"Timeout": 30,
},
// ControllerConfig
"Options": {
"Core": "sing",
"EnableProxyProtocol": true,
"EnableTFO": true
"DomainStrategy": "ipv4_only",
// More
}
},
{
// Xray
"Core": "xray",
"ApiHost": "http://127.0.0.1",
"ApiKey": "test",
"NodeID": 33,
"NodeType": "shadowsocks",
"Timeout": 30,
"ListenIP": "0.0.0.0",
"SendIP": "0.0.0.0",
"EnableProxyProtocol": true,
"EnableTFO": true
// More
}*/
]
}

227
example/config_full.json Normal file
View File

@ -0,0 +1,227 @@
{
"Log": {
// V2bX Core log
// info, warn, error, none
"Level": "error",
//
"Output": ""
},
"Cores": [
{
// Core
"Type": "sing",
// Core
"Name": "sing1",
"Log": {
// SingBox log
"Level": "error",
"Timestamp": true
},
"NTP": {
// SingBox ntp
// VMess VLESS
"Enable": true,
"Server": "time.apple.com",
"ServerPort": 0
},
// SingBoxSingBox
"OriginalPath": "/etc/V2bX/sing_origin.json"
},
{
"Type": "sing",
"Name": "sing2",
"Log": {
"Level": "info",
"Timestamp": false
},
},
{
"Type": "xray",
"Log": {
// Xray-core log
"Level": "error"
},
//
"AssetPath": "",
// DNS
"DnsConfigPath": "",
//
"RouteConfigPath": "",
//
"ConnectionConfig": {
// https://xtls.github.io/config/policy.html#levelpolicyobject
"handshake": 4,
"connIdle": 300,
"uplinkOnly": 2,
"downlinkOnly": 5,
"statsUserUplink": false,
"statsUserDownlink": false,
"bufferSize": 4
},
// Inbound
"InboundConfigPath": "",
// Outbound
"OutboundConfigPath": ""
}
],
"Nodes": [
// Node
{
// 1
// Node便
//
"Name": "sing_node1",
// 使Core
// CoreName
// CoreCoreName
"Core": "sing",
// 使Core
"CoreName": "sing1",
// API
"ApiHost": "http://127.0.0.1",
// APIToken
"ApiKey": "test",
// ID
"NodeID": 33,
//
"NodeType": "shadowsocks",
//
"Timeout": 30,
// IP
"ListenIP": "0.0.0.0",
// IP
"SendIP": "0.0.0.0",
// Proxy Protocol https://github.com/haproxy/haproxy/blob/master/doc/proxy-protocol.txt
"EnableProxyProtocol": false,
// TCP Fast Open
"EnableTFO": true,
// Domain Strategy
// prefer_ipv4 / prefer_ipv6 / ipv4_only / ipv6_only
"DomainStrategy": "ipv4_only",
//
"LimitConfig": {
// IP
"EnableRealtime": false,
//
"SpeedLimit": 0,
// IP
"IPLimit": 0,
//
"ConnLimit": 0,
//
"EnableDynamicSpeedLimit": false,
//
"DynamicSpeedLimitConfig": {
//
"Periodic": 60,
//
"Traffic": 1000,
//
"SpeedLimit": 100,
//
"ExpireTime": 60
}
},
//
"CertConfig": {
// nonehttpdnsself
"CertMode": "none",
"RejectUnknownSni": false,
//
"CertDomain": "test.com",
//
"CertFile": "/etc/V2bX/cert/1.pem",
//
"KeyFile": "/etc/V2bX/cert/1.key",
// 使
"Email": "1@test.com",
// DNS
"Provider": "cloudflare",
// DNS https://go-acme.github.io/lego/dns/
"DNSEnv": {
"EnvName": "env1"
}
}
},
{
//
"Include": "../example/config_full_node1.json",
}
/*,
{
// 2
// ApiConfig
"ApiConfig": {
"ApiHost": "http://127.0.0.1",
"ApiKey": "test",
"NodeID": 33,
"Timeout": 30,
},
// ControllerConfig
"Options": {
"Core": "sing",
"EnableProxyProtocol": true,
"EnableTFO": true
"DomainStrategy": "ipv4_only",
// More
}
},
{
// Xray
"Core": "xray",
"ApiHost": "http://127.0.0.1",
"ApiKey": "test",
"NodeID": 33,
"NodeType": "shadowsocks",
"Timeout": 30,
"ListenIP": "0.0.0.0",
"SendIP": "0.0.0.0",
"EnableProxyProtocol": true,
"EnableTFO": true
// More
}*/
]
}