mirror of
https://github.com/nitezs/sub2sing-box.git
synced 2024-12-23 10:34:42 -05:00
📝 Modify templates
This commit is contained in:
parent
9f8bca3804
commit
095c855259
60
templates/linux/dns.json
Normal file
60
templates/linux/dns.json
Normal file
@ -0,0 +1,60 @@
|
||||
{
|
||||
"dns": {
|
||||
"servers": [
|
||||
{
|
||||
"tag": "google",
|
||||
"address": "tls://8.8.8.8",
|
||||
"detour": "default"
|
||||
},
|
||||
{
|
||||
"tag": "local",
|
||||
"address": "https://223.5.5.5/dns-query",
|
||||
"detour": "direct"
|
||||
},
|
||||
{
|
||||
"tag": "refused",
|
||||
"address": "rcode://refused"
|
||||
}
|
||||
],
|
||||
"rules": [
|
||||
{
|
||||
"rule_set": "geosite-category-ads-all",
|
||||
"server": "refused"
|
||||
},
|
||||
{
|
||||
"outbound": "any",
|
||||
"server": "local"
|
||||
},
|
||||
{
|
||||
"clash_mode": "Direct",
|
||||
"server": "local"
|
||||
},
|
||||
{
|
||||
"clash_mode": "Global",
|
||||
"server": "google"
|
||||
},
|
||||
{
|
||||
"rule_set": "geosite-geolocation-cn",
|
||||
"server": "local"
|
||||
},
|
||||
{
|
||||
"type": "logical",
|
||||
"mode": "and",
|
||||
"rules": [
|
||||
{
|
||||
"rule_set": "geosite-geolocation-!cn",
|
||||
"invert": true
|
||||
},
|
||||
{
|
||||
"rule_set": "geoip-cn"
|
||||
}
|
||||
],
|
||||
"server": "google",
|
||||
"client_subnet": "114.114.114.114/24"
|
||||
}
|
||||
],
|
||||
"final": "local",
|
||||
"disable_cache": false,
|
||||
"disable_expire": false
|
||||
}
|
||||
}
|
13
templates/linux/experimental.json
Normal file
13
templates/linux/experimental.json
Normal file
@ -0,0 +1,13 @@
|
||||
{
|
||||
"experimental": {
|
||||
"cache_file": {
|
||||
"enabled": true
|
||||
},
|
||||
"clash_api": {
|
||||
"external_controller": "127.0.0.1:9090",
|
||||
"external_ui": "./ui",
|
||||
"external_ui_download_detour": "default",
|
||||
"default_mode": "Enhanced"
|
||||
}
|
||||
}
|
||||
}
|
14
templates/linux/inbounds.json
Normal file
14
templates/linux/inbounds.json
Normal file
@ -0,0 +1,14 @@
|
||||
{
|
||||
"inbounds": [
|
||||
{
|
||||
"type": "tun",
|
||||
"auto_route": true,
|
||||
"auto_redirect": true,
|
||||
"strict_route": true,
|
||||
"sniff": true,
|
||||
"sniff_override_destination": true,
|
||||
"address": ["172.16.0.1/30", "fdfe:dcba:9876::1/126"],
|
||||
"exclude_interface": ["tailscale0"]
|
||||
}
|
||||
]
|
||||
}
|
6
templates/linux/log.json
Normal file
6
templates/linux/log.json
Normal file
@ -0,0 +1,6 @@
|
||||
{
|
||||
"log": {
|
||||
"level": "trace",
|
||||
"timestamp": true
|
||||
}
|
||||
}
|
53
templates/linux/route.json
Normal file
53
templates/linux/route.json
Normal file
@ -0,0 +1,53 @@
|
||||
{
|
||||
"route": {
|
||||
"rules": [
|
||||
{
|
||||
"type": "logical",
|
||||
"mode": "or",
|
||||
"rules": [
|
||||
{
|
||||
"protocol": "dns"
|
||||
},
|
||||
{
|
||||
"port": 53
|
||||
}
|
||||
],
|
||||
"outbound": "dns"
|
||||
},
|
||||
{
|
||||
"ip_is_private": true,
|
||||
"outbound": "direct"
|
||||
},
|
||||
{
|
||||
"clash_mode": "Direct",
|
||||
"outbound": "direct"
|
||||
},
|
||||
{
|
||||
"clash_mode": "Global",
|
||||
"outbound": "default"
|
||||
},
|
||||
{
|
||||
"rule_set": "geosite-google",
|
||||
"outbound": "default"
|
||||
},
|
||||
{
|
||||
"type": "logical",
|
||||
"mode": "or",
|
||||
"rules": [
|
||||
{
|
||||
"rule_set": [
|
||||
"geoip-cn",
|
||||
"geosite-geolocation-cn",
|
||||
"geosite-cn",
|
||||
"geosite-category-games@cn",
|
||||
"geosite-steam@cn"
|
||||
]
|
||||
}
|
||||
],
|
||||
"outbound": "direct"
|
||||
}
|
||||
],
|
||||
"final": "default",
|
||||
"auto_detect_interface": true
|
||||
}
|
||||
}
|
62
templates/linux/route_rule_set.json
Normal file
62
templates/linux/route_rule_set.json
Normal file
@ -0,0 +1,62 @@
|
||||
{
|
||||
"route": {
|
||||
"rule_set": [
|
||||
{
|
||||
"type": "remote",
|
||||
"tag": "geosite-category-ads-all",
|
||||
"format": "binary",
|
||||
"url": "https://ghp.ci/https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-category-ads-all.srs",
|
||||
"download_detour": "default"
|
||||
},
|
||||
{
|
||||
"type": "remote",
|
||||
"tag": "geosite-geolocation-cn",
|
||||
"format": "binary",
|
||||
"url": "https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-geolocation-cn.srs",
|
||||
"download_detour": "default"
|
||||
},
|
||||
{
|
||||
"type": "remote",
|
||||
"tag": "geosite-geolocation-!cn",
|
||||
"format": "binary",
|
||||
"url": "https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-geolocation-!cn.srs",
|
||||
"download_detour": "default"
|
||||
},
|
||||
{
|
||||
"type": "remote",
|
||||
"tag": "geoip-cn",
|
||||
"format": "binary",
|
||||
"url": "https://raw.githubusercontent.com/SagerNet/sing-geoip/rule-set/geoip-cn.srs",
|
||||
"download_detour": "default"
|
||||
},
|
||||
{
|
||||
"type": "remote",
|
||||
"tag": "geosite-category-games@cn",
|
||||
"format": "binary",
|
||||
"url": "https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-category-games@cn.srs",
|
||||
"download_detour": "default"
|
||||
},
|
||||
{
|
||||
"type": "remote",
|
||||
"tag": "geosite-steam@cn",
|
||||
"format": "binary",
|
||||
"url": "https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-steam@cn.srs",
|
||||
"download_detour": "default"
|
||||
},
|
||||
{
|
||||
"type": "remote",
|
||||
"tag": "geosite-cn",
|
||||
"format": "binary",
|
||||
"url": "https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-cn.srs",
|
||||
"download_detour": "default"
|
||||
},
|
||||
{
|
||||
"type": "remote",
|
||||
"tag": "geosite-google",
|
||||
"format": "binary",
|
||||
"url": "https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-google.srs",
|
||||
"download_detour": "default"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
60
templates/windows/dns.json
Normal file
60
templates/windows/dns.json
Normal file
@ -0,0 +1,60 @@
|
||||
{
|
||||
"dns": {
|
||||
"servers": [
|
||||
{
|
||||
"tag": "google",
|
||||
"address": "tls://8.8.8.8",
|
||||
"detour": "default"
|
||||
},
|
||||
{
|
||||
"tag": "local",
|
||||
"address": "https://223.5.5.5/dns-query",
|
||||
"detour": "direct"
|
||||
},
|
||||
{
|
||||
"tag": "refused",
|
||||
"address": "rcode://refused"
|
||||
}
|
||||
],
|
||||
"rules": [
|
||||
{
|
||||
"rule_set": "geosite-category-ads-all",
|
||||
"server": "refused"
|
||||
},
|
||||
{
|
||||
"outbound": "any",
|
||||
"server": "local"
|
||||
},
|
||||
{
|
||||
"clash_mode": "Direct",
|
||||
"server": "local"
|
||||
},
|
||||
{
|
||||
"clash_mode": "Global",
|
||||
"server": "google"
|
||||
},
|
||||
{
|
||||
"rule_set": "geosite-geolocation-cn",
|
||||
"server": "local"
|
||||
},
|
||||
{
|
||||
"type": "logical",
|
||||
"mode": "and",
|
||||
"rules": [
|
||||
{
|
||||
"rule_set": "geosite-geolocation-!cn",
|
||||
"invert": true
|
||||
},
|
||||
{
|
||||
"rule_set": "geoip-cn"
|
||||
}
|
||||
],
|
||||
"server": "google",
|
||||
"client_subnet": "114.114.114.114/24"
|
||||
}
|
||||
],
|
||||
"final": "local",
|
||||
"disable_cache": false,
|
||||
"disable_expire": false
|
||||
}
|
||||
}
|
13
templates/windows/experimental.json
Normal file
13
templates/windows/experimental.json
Normal file
@ -0,0 +1,13 @@
|
||||
{
|
||||
"experimental": {
|
||||
"cache_file": {
|
||||
"enabled": true
|
||||
},
|
||||
"clash_api": {
|
||||
"external_controller": "127.0.0.1:9090",
|
||||
"external_ui": "./ui",
|
||||
"external_ui_download_detour": "default",
|
||||
"default_mode": "Enhanced"
|
||||
}
|
||||
}
|
||||
}
|
13
templates/windows/inbounds.json
Normal file
13
templates/windows/inbounds.json
Normal file
@ -0,0 +1,13 @@
|
||||
{
|
||||
"inbounds": [
|
||||
{
|
||||
"type": "tun",
|
||||
"auto_route": true,
|
||||
"strict_route": true,
|
||||
"sniff": true,
|
||||
"sniff_override_destination": true,
|
||||
"address": ["172.16.0.1/30", "fdfe:dcba:9876::1/126"],
|
||||
"exclude_interface": ["tailscale0"]
|
||||
}
|
||||
]
|
||||
}
|
6
templates/windows/log.json
Normal file
6
templates/windows/log.json
Normal file
@ -0,0 +1,6 @@
|
||||
{
|
||||
"log": {
|
||||
"level": "trace",
|
||||
"timestamp": true
|
||||
}
|
||||
}
|
21
templates/windows/outbounds.json
Normal file
21
templates/windows/outbounds.json
Normal file
@ -0,0 +1,21 @@
|
||||
{
|
||||
"outbounds": [
|
||||
{
|
||||
"outbounds": ["<all-proxy-tags>", "direct"],
|
||||
"tag": "default",
|
||||
"type": "selector"
|
||||
},
|
||||
{
|
||||
"tag": "direct",
|
||||
"type": "direct"
|
||||
},
|
||||
{
|
||||
"tag": "block",
|
||||
"type": "block"
|
||||
},
|
||||
{
|
||||
"tag": "dns",
|
||||
"type": "dns"
|
||||
}
|
||||
]
|
||||
}
|
53
templates/windows/route.json
Normal file
53
templates/windows/route.json
Normal file
@ -0,0 +1,53 @@
|
||||
{
|
||||
"route": {
|
||||
"rules": [
|
||||
{
|
||||
"type": "logical",
|
||||
"mode": "or",
|
||||
"rules": [
|
||||
{
|
||||
"protocol": "dns"
|
||||
},
|
||||
{
|
||||
"port": 53
|
||||
}
|
||||
],
|
||||
"outbound": "dns"
|
||||
},
|
||||
{
|
||||
"ip_is_private": true,
|
||||
"outbound": "direct"
|
||||
},
|
||||
{
|
||||
"clash_mode": "Direct",
|
||||
"outbound": "direct"
|
||||
},
|
||||
{
|
||||
"clash_mode": "Global",
|
||||
"outbound": "default"
|
||||
},
|
||||
{
|
||||
"rule_set": "geosite-google",
|
||||
"outbound": "default"
|
||||
},
|
||||
{
|
||||
"type": "logical",
|
||||
"mode": "or",
|
||||
"rules": [
|
||||
{
|
||||
"rule_set": [
|
||||
"geoip-cn",
|
||||
"geosite-geolocation-cn",
|
||||
"geosite-cn",
|
||||
"geosite-category-games@cn",
|
||||
"geosite-steam@cn"
|
||||
]
|
||||
}
|
||||
],
|
||||
"outbound": "direct"
|
||||
}
|
||||
],
|
||||
"final": "default",
|
||||
"auto_detect_interface": true
|
||||
}
|
||||
}
|
62
templates/windows/route_rule_set.json
Normal file
62
templates/windows/route_rule_set.json
Normal file
@ -0,0 +1,62 @@
|
||||
{
|
||||
"route": {
|
||||
"rule_set": [
|
||||
{
|
||||
"type": "remote",
|
||||
"tag": "geosite-category-ads-all",
|
||||
"format": "binary",
|
||||
"url": "https://ghp.ci/https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-category-ads-all.srs",
|
||||
"download_detour": "default"
|
||||
},
|
||||
{
|
||||
"type": "remote",
|
||||
"tag": "geosite-geolocation-cn",
|
||||
"format": "binary",
|
||||
"url": "https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-geolocation-cn.srs",
|
||||
"download_detour": "default"
|
||||
},
|
||||
{
|
||||
"type": "remote",
|
||||
"tag": "geosite-geolocation-!cn",
|
||||
"format": "binary",
|
||||
"url": "https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-geolocation-!cn.srs",
|
||||
"download_detour": "default"
|
||||
},
|
||||
{
|
||||
"type": "remote",
|
||||
"tag": "geoip-cn",
|
||||
"format": "binary",
|
||||
"url": "https://raw.githubusercontent.com/SagerNet/sing-geoip/rule-set/geoip-cn.srs",
|
||||
"download_detour": "default"
|
||||
},
|
||||
{
|
||||
"type": "remote",
|
||||
"tag": "geosite-category-games@cn",
|
||||
"format": "binary",
|
||||
"url": "https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-category-games@cn.srs",
|
||||
"download_detour": "default"
|
||||
},
|
||||
{
|
||||
"type": "remote",
|
||||
"tag": "geosite-steam@cn",
|
||||
"format": "binary",
|
||||
"url": "https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-steam@cn.srs",
|
||||
"download_detour": "default"
|
||||
},
|
||||
{
|
||||
"type": "remote",
|
||||
"tag": "geosite-cn",
|
||||
"format": "binary",
|
||||
"url": "https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-cn.srs",
|
||||
"download_detour": "default"
|
||||
},
|
||||
{
|
||||
"type": "remote",
|
||||
"tag": "geosite-google",
|
||||
"format": "binary",
|
||||
"url": "https://raw.githubusercontent.com/SagerNet/sing-geosite/rule-set/geosite-google.srs",
|
||||
"download_detour": "default"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user