| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465 |
- <?php
- declare(strict_types=1);
- /**
- * default 为默认配置,你可以添加其他配置,但必须保证默认配置存在
- *
- * Checks 填写为没有直接在规则文件中使用的并且使用了筛选规则且组内或可能无节点的策略组名
- * - 例如使用 regex 分类国家分组,未匹配时组内无节点,此类需要填入 Checks 中以保证配置文件无误
- *
- * Surge 以及 Surfboard 的 General 中,布尔值请填写为字符串
- *
- * Surge 以及 Surfboard 的 Proxy 中,请填写为该应用的格式
- * Clash 的 Proxy 中,请填写为数组
- */
- /**
- * Surge 配置文件定义
- */
- $_ENV['Surge_Profiles'] = [
- 'default' => [
- 'Checks' => [],
- 'General' => [
- 'loglevel' => 'notify',
- 'dns-server' => 'system, 119.29.29.29, 1.1.1.1',
- 'skip-proxy' => '127.0.0.1, 192.168.0.0/16, 10.0.0.0/8, 172.16.0.0/12, 100.64.0.0/10, 17.0.0.0/8, localhost, *.local, *.crashlytics.com',
- 'external-controller-access' => '[email protected]:8233',
- 'allow-wifi-access' => 'true',
- 'enhanced-mode-by-rule' => 'false',
- 'exclude-simple-hostnames' => 'true',
- 'show-error-page-for-reject' => 'true',
- 'ipv6' => 'true',
- 'replica' => 'false',
- 'http-listen' => '0.0.0.0:8234',
- 'socks5-listen' => '0.0.0.0:8235',
- 'wifi-access-http-port' => 6152,
- 'wifi-access-socks5-port' => 6153,
- 'internet-test-url' => 'http://wifi.vivo.com.cn/generate_204',
- 'proxy-test-url' => 'http://cp.cloudflare.com',
- 'test-timeout' => 3,
- ],
- 'Proxy' => [
- '🚀直接连接 = direct',
- ],
- 'ProxyGroup' => [
- [
- 'name' => '🔰国外流量',
- 'type' => 'select',
- 'content' => [
- 'regex' => '(.*)',
- 'right-proxies' => [
- '🚀直接连接',
- ],
- ],
- ],
- [
- 'name' => '⚓️其他流量',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- '🚀直接连接',
- ],
- ],
- ],
- [
- 'name' => '✈️Telegram',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🎬Youtube',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🎬Netflix',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🎬哔哩哔哩',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🚀直接连接',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🎬国外媒体',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🍎苹果服务',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🚀直接连接',
- '🔰国外流量',
- ],
- ],
- ],
- ],
- 'Rule' => [
- 'source' => 'surge/default.tpl',
- ],
- ],
- ];
- /**
- * Surge 2.x 版本的配置文件定义
- */
- $_ENV['Surge2_Profiles'] = [
- 'default' => [
- 'Checks' => [],
- 'General' => [
- 'loglevel' => 'notify',
- 'ipv6' => 'true',
- 'replica' => 'false',
- 'dns-server' => 'system, 119.29.29.29, 1.1.1.1',
- 'skip-proxy' => '127.0.0.1, 192.168.0.0/16, 10.0.0.0/8, 172.16.0.0/12, 100.64.0.0/10, 17.0.0.0/8, localhost, *.local, *.crashlytics.com',
- 'bypass-system' => 'true',
- 'allow-wifi-access' => 'true',
- 'external-controller-access' => '[email protected]:8233',
- ],
- 'Proxy' => [
- '🚀直接连接 = direct',
- ],
- 'ProxyGroup' => [
- [
- 'name' => '🔰国外流量',
- 'type' => 'select',
- 'content' => [
- 'regex' => '(.*)',
- 'right-proxies' => [
- '🚀直接连接',
- ],
- ],
- ],
- [
- 'name' => '⚓️其他流量',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- '🚀直接连接',
- ],
- ],
- ],
- [
- 'name' => '✈️Telegram',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🎬Youtube',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🎬Netflix',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🎬哔哩哔哩',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🚀直接连接',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🎬国外媒体',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🍎苹果服务',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🚀直接连接',
- '🔰国外流量',
- ],
- ],
- ],
- ],
- 'Rule' => [
- 'source' => 'surge2/default.tpl',
- ],
- ],
- ];
- /**
- * Clash 配置文件定义
- */
- $_ENV['Clash_Profiles'] = [
- 'default' => [
- 'Checks' => [],
- 'General' => [
- 'port' => 7890,
- 'socks-port' => 7891,
- 'redir-port' => 7892,
- 'allow-lan' => false,
- 'mode' => 'rule',
- 'log-level' => 'silent',
- 'external-controller' => '0.0.0.0:9090',
- 'secret' => '',
- ],
- 'DNS' => [
- 'enable' => true,
- 'ipv6' => false,
- 'listen' => '0.0.0.0:53',
- 'enhanced-mode' => 'fake-ip',
- 'fake-ip-range' => '198.18.0.1/16',
- 'nameserver' => [
- '119.29.29.29',
- '1.1.1.1',
- ],
- 'fallback' => [
- '1.0.0.1',
- '8.8.8.8',
- ],
- 'fallback-filter' => [
- 'geoip' => true,
- 'ipcidr' => [
- '240.0.0.0/4',
- ],
- ],
- ],
- 'Proxy' => [],
- 'ProxyGroup' => [
- [
- 'name' => '🔰国外流量',
- 'type' => 'select',
- 'content' => [
- 'regex' => '(.*)',
- 'right-proxies' => [
- '🚀直接连接',
- ],
- ],
- ],
- [
- 'name' => '⚓️其他流量',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- '🚀直接连接',
- ],
- ],
- ],
- [
- 'name' => '✈️Telegram',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🎬Youtube',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🎬Netflix',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🎬哔哩哔哩',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🚀直接连接',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🎬国外媒体',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🍎苹果服务',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🚀直接连接',
- '🔰国外流量',
- ],
- ],
- ],
- [
- 'name' => '🚀直接连接',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- 'DIRECT',
- ],
- ],
- ],
- ],
- 'Rule' => [
- 'source' => 'clash/default.tpl',
- ],
- ],
- ];
- /**
- * Surfboard 配置文件定义
- */
- $_ENV['Surfboard_Profiles'] = [
- 'default' => [
- 'Checks' => [],
- 'General' => [
- 'loglevel' => 'notify',
- 'dns-server' => 'system, 119.29.29.29, 1.1.1.1',
- 'skip-proxy' => '127.0.0.1, 192.168.0.0/16, 10.0.0.0/8, 172.16.0.0/12, 100.64.0.0/10, 17.0.0.0/8, localhost, *.local, *.crashlytics.com',
- ],
- 'Proxy' => [
- '🚀直接连接 = direct',
- ],
- 'ProxyGroup' => [
- [
- 'name' => '🔰国外流量',
- 'type' => 'select',
- 'content' => [
- 'regex' => '(.*)',
- 'right-proxies' => [
- '🚀直接连接',
- ],
- ],
- ],
- [
- 'name' => '⚓️其他流量',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- '🚀直接连接',
- ],
- ],
- ],
- [
- 'name' => '✈️Telegram',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🎬Youtube',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🎬Netflix',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🎬哔哩哔哩',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🚀直接连接',
- ],
- 'regex' => '(.*)',
- ],
- ],
- [
- 'name' => '🎬国外媒体',
- 'type' => 'select',
- 'content' => [
- 'left-proxies' => [
- '🔰国外流量',
- ],
- 'regex' => '(.*)',
- ],
- ],
- ],
- 'Rule' => [
- 'source' => 'surfboard/default.tpl',
- ],
- ],
- ];
|