- stun.l.google.com
- na.b.g-tun.com
- "+.nflxvideo.net"
- "*.square-enix.com"
- "*.finalfantasyxiv.com"
- "*.ffxiv.com"
- "*.ff14.sdo.com"
- ff.dorado.sdo.com
- "*.mcdn.bilivideo.cn"
- "+.media.dssott.com"
- shark007.net
- Mijia Cloud
- "+.cmbchina.com"
- "+.cmbimg.com"
- local.adguard.org
- "+.sandai.net"
- "+.n0808.com"
- "+.uu.163.com"
- ps.res.netease.com
- "+.pub.3gppnetwork.org"
- rule-set:oc-cn-domain
proxy-groups:
- type: select
name: "\U0001F680 节点选择"
proxies:
- " 自动选择"
- DIRECT
- REJECT
use:
- _auto_provider_ncqswh
- name: " 自动选择"
type: url-test
proxies: []
url: http://www.gstatic.com/generate_204
interval: 300
lazy: false
use:
- _auto_provider_ncqswh
- type: select
name: "\U0001F4AC AI 服务"
proxies:
- "\U0001F680 节点选择"
- DIRECT
- REJECT
use:
- _auto_provider_ncqswh
- type: select
name: "\U0001F4F9 油管视频"
proxies:
- "\U0001F680 节点选择"
- DIRECT
- REJECT
use:
- _auto_provider_ncqswh
- type: select
name: "\U0001F50D 谷歌服务"
proxies:
- "\U0001F680 节点选择"
- DIRECT
- REJECT
use:
- _auto_provider_ncqswh
- type: select
name: "\U0001F3E0 私有网络"
proxies:
- DIRECT
- "\U0001F680 节点选择"
- REJECT
use:
- _auto_provider_ncqswh
- type: select
name: "\U0001F512 国内服务"
proxies:
- DIRECT
- "\U0001F680 节点选择"
- REJECT
use:
- _auto_provider_ncqswh
- type: select
name: "\U0001F4F2 电报消息"
proxies:
- "\U0001F680 节点选择"
- DIRECT
- REJECT
use:
- _auto_provider_ncqswh
- type: select
name: "\U0001F431 Github"
proxies:
- "\U0001F680 节点选择"
- DIRECT
- REJECT
use:
- _auto_provider_ncqswh
- type: select
name: "\U0001F310 非中国"
proxies:
- "\U0001F680 节点选择"
- DIRECT
- REJECT
use:
- _auto_provider_ncqswh
- type: select
name: "\U0001F41F 漏网之鱼"
proxies:
- "\U0001F680 节点选择"
- DIRECT
- REJECT
use:
- _auto_provider_ncqswh
rules:
- "RULE-SET,category-ai-!cn,\U0001F4AC AI 服务"
- "RULE-SET,youtube,\U0001F4F9 油管视频"
- "RULE-SET,google,\U0001F50D 谷歌服务"
- "RULE-SET,geolocation-cn,\U0001F512 国内服务"
- "RULE-SET,cn,\U0001F512 国内服务"
- "RULE-SET,github,\U0001F431 Github"
- "RULE-SET,gitlab,\U0001F431 Github"
- "RULE-SET,geolocation-!cn,\U0001F310 非中国"
- "RULE-SET,google-ip,\U0001F50D 谷歌服务,no-resolve"
- "RULE-SET,private-ip,\U0001F3E0 私有网络,no-resolve"
- "RULE-SET,cn-ip,\U0001F512 国内服务,no-resolve"
- "RULE-SET,telegram-ip,\U0001F4F2 电报消息,no-resolve"
- "MATCH,\U0001F41F 漏网之鱼"
redir-port: 7892
tproxy-port: 7895
mixed-port: 7893
external-controller: 0.0.*.*:9090
bind-address: "*"
external-ui: "/usr/share/openclash/ui"
external-ui-name: zashboard
external-ui-url: https://codeload.github.com/Zephyruso/zashboard/zip/refs/heads/gh-pages-cdn-fonts
keep-alive-interval: 15
keep-alive-idle: 600
ipv6: false
experimental:
quic-go-disable-gso: true
profile:
store-selected: true
store-fake-ip: true
ntp:
enable: true
server: time.apple.com
port: 123
interval: 30
write-to-system: true


## 自定义覆写设置
bash
# cat /etc/openclash/custom/openclash_custom_overwrite.sh
#!/bin/sh
. /usr/share/openclash/ruby.sh
. /usr/share/openclash/log.sh
. /lib/functions.sh

# This script is called by /etc/init.d/openclash
# Add your custom overwrite scripts here, they will be take effict after the OpenClash own srcipts

LOG_OUT "Tip: Start Running Custom Overwrite Scripts..."
LOGTIME=$(echo $(date "+%Y-%m-%d %H:%M:%S"))
LOG_FILE="/tmp/openclash.log"
#Config Path
CONFIG_FILE="$1"

#Simple Demo:
#Key Overwrite Demo
#1--config path
#2--key name
#3--value
#ruby_edit "$CONFIG_FILE" "['redir-port']" "7892"
#ruby_edit "$CONFIG_FILE" "['secret']" "123456"
#ruby_edit "$CONFIG_FILE" "['dns']['enable']" "true"
#ruby_edit "$CONFIG_FILE" "['dns']['proxy-server-nameserver']" "['https://doh.pub/dns-query','https://223.5.*.*:443/dns-query']"
 
 
Back to Top