diff --git a/README.md b/README.md index d8b61d3..b18416d 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# 一键脚本快速安装 +# Xray-core/sing-box 一键脚本快速安装 - [感谢 JetBrains 提供的非商业开源软件开发授权](https://www.jetbrains.com/?from=v2ray-agent) - [Thanks for non-commercial open source development authorization by JetBrains](https://www.jetbrains.com/?from=v2ray-agent) @@ -13,21 +13,44 @@ # 一、项目介绍 -- [一键安装教程【推荐】](https://www.v2ray-agent.com/archives/1682491479771) -- 支持Xray-core/sing-box/Hysteria/Tuic -- 支持多种传输协议,VLESS(Reality)、VMess、Trojan、Hysteria、Tuic,支持多种协议组合。 -- 支持自动申请和更新证书 -- 支持自主更换伪装站点 -- [支持批量添加CDN节点并配合ClashMeta自动优选](https://www.v2ray-agent.com/archives/1684858575649) -- 支持订阅以及多VPS组合订阅 -- [支持多种分流工具(Warp、IPv6、任意门、DNS、VMess(ws)、SNI反向代理)](https://www.v2ray-agent.com/archives/ba-he-yi-jiao-ben-yu-ming-fen-liu-jiao-cheng) -- 支持批量新增端口 -- 支持Core的升级以及回退 -- [支持无域名版本的VLESS Reality搭建](https://www.v2ray-agent.com/archives/1680104902581) -- [Reality教程和介绍【推荐】](https://www.v2ray-agent.com/archives/1680104902581) -- [搭建最新的Vision和Reality防止VPS端口封禁](https://www.v2ray-agent.com/archives/1680104902581) +## 核心 -# 二、线路推荐 +- Xray-core +- v2ray-core[暂停维护] +- sing-box + +## 协议 + +> 以下均使用TLS,支持多种协议组合 + +- VLESS(Reality、Vision、TCP、WS、gRPC) +- VMess(TCP、WS) +- Trojan(TCP、gRPC) +- Hysteria2 +- Tuic + +## 功能 + +- [支持无域名版本的VLESS Reality搭建](https://www.v2ray-agent.com/archives/1680104902581) +- [支持多种分流用于解锁(wireguard、IPv6、任意门、DNS、VMess(ws)、SNI反向代理)](https://www.v2ray-agent.com/archives/ba-he-yi-jiao-ben-yu-ming-fen-liu-jiao-cheng) +- [支持批量添加CDN节点并配合ClashMeta自动优选](https://www.v2ray-agent.com/archives/1684858575649) +- 支持证书自动申请及更新 +- [支持订阅以及多VPS组合订阅](https://www.v2ray-agent.com/archives/1681804748677) +- 支持批量新增端口 +- 支持核心的升级以及回退 +- 支持自主更换伪装站点 +- 支持BT下载管理以及域名黑名单管理 + + +# 二、使用指南 + +- [脚本快速搭建教程](https://www.v2ray-agent.com/archives/1682491479771) +- [垃圾VPS大救星,hysteria2最新协议一键搭建](https://www.v2ray-agent.com/archives/1697162969693) +- [Tuic V5性能提升及使用方法](https://www.v2ray-agent.com/archives/1687167522196) +- [Cloudflare优选IP、自动选择最快节点教程](https://www.v2ray-agent.com/archives/1684858575649) +- [脚本异常处理](https://www.v2ray-agent.com/archives/1684115970026) + +# 三、线路推荐 > 再好的协议也比不上一个高品质的VPS。推荐以下线路 @@ -38,7 +61,7 @@ - [日本软银](https://www.v2ray-agent.com/tags/ruan-yin) - [CMI](https://www.v2ray-agent.com/tags/cmi) -# 三、安装使用 +# 四、安装使用 ## 1.下载脚本 @@ -56,7 +79,7 @@ wget -P /root -N --no-check-certificate "https://raw.githubusercontent.com/mack- wget -P /root -N --no-check-certificate "https://www.v2ray-agent.com/v2ray-agent/install.sh" && chmod 700 /root/install.sh && /root/install.sh ``` -## [2.搭建教程](https://www.v2ray-agent.com/archives/1682491479771) +## [2.脚本快速搭建教程](https://www.v2ray-agent.com/archives/1682491479771) # 四、反馈和建议 @@ -74,7 +97,3 @@ wget -P /root -N --no-check-certificate "https://www.v2ray-agent.com/v2ray-agent # 六、许可证 [AGPL-3.0](https://github.com/mack-a/v2ray-agent/blob/master/LICENSE) - -## Stargazers over time - -[![Stargazers over time](https://starchart.cc/mack-a/v2ray-agent.svg)](https://starchart.cc/mack-a/v2ray-agent) diff --git a/install.sh b/install.sh index 2699938..9861ba7 100644 --- a/install.sh +++ b/install.sh @@ -3157,14 +3157,14 @@ EOF # 初始化singbox route配置 initSingBoxRouteConfig() { + downloadSingBoxGeositeDB local outboundTag=$1 if [[ ! -f "${singBoxConfigPath}config/${outboundTag}_route.json" ]]; then cat <"${singBoxConfigPath}config/${outboundTag}_route.json" { "route": { "geosite": { - "path": "${singBoxConfigPath}geosite.db", - "download_url": "https://github.com/SagerNet/sing-geosite/releases/latest/download/geosite.db" + "path": "${singBoxConfigPath}geosite.db" }, "rules": [ { @@ -3180,6 +3180,12 @@ initSingBoxRouteConfig() { EOF fi } +# 下载sing-box geosite db +downloadSingBoxGeositeDB() { + if [[ ! -f "${singBoxConfigPath}geosite.db" ]]; then + wget -q -P "${singBoxConfigPath}" https://github.com/Johnshall/sing-geosite/releases/latest/download/geosite.db + fi +} # sing-box 路由规则配置配置 configurationSingBoxRoute() { @@ -4622,7 +4628,7 @@ showAccounts() { local show # VLESS TCP if echo "${currentInstallProtocolType}" | grep -q trojan; then - echoContent skyBlue "===================== Trojan TCP TLS_Vision ======================\n" + echoContent skyBlue "===================== Trojan TCP TLS_Vision[不推荐] ======================\n" jq .inbounds[0].settings.clients ${configPath}02_trojan_TCP_inbounds.json | jq -c '.[]' | while read -r user; do local email= email=$(echo "${user}" | jq -r .email) @@ -4645,7 +4651,7 @@ showAccounts() { # VLESS WS if echo ${currentInstallProtocolType} | grep -q 1; then - echoContent skyBlue "\n================================ VLESS WS TLS CDN ================================\n" + echoContent skyBlue "\n================================ VLESS WS TLS [仅CDN不推荐] ================================\n" jq .inbounds[0].settings.clients ${configPath}03_VLESS_WS_inbounds.json | jq -c '.[]' | while read -r user; do local email= @@ -4667,7 +4673,7 @@ showAccounts() { # VLESS grpc if echo ${currentInstallProtocolType} | grep -q 5; then - echoContent skyBlue "\n=============================== VLESS gRPC TLS CDN ===============================\n" + echoContent skyBlue "\n=============================== VLESS gRPC TLS [仅CDN不推荐] ===============================\n" jq .inbounds[0].settings.clients ${configPath}06_VLESS_gRPC_inbounds.json | jq -c '.[]' | while read -r user; do local email= @@ -4688,7 +4694,7 @@ showAccounts() { # VMess WS if echo ${currentInstallProtocolType} | grep -q 3; then - echoContent skyBlue "\n================================ VMess WS TLS CDN ================================\n" + echoContent skyBlue "\n================================ VMess WS TLS [仅CDN不推荐] ================================\n" local path="${currentPath}vws" if [[ ${coreInstallType} == "1" ]]; then path="${currentPath}vws" @@ -4711,7 +4717,7 @@ showAccounts() { # trojan tcp if echo ${currentInstallProtocolType} | grep -q 4; then - echoContent skyBlue "\n================================== Trojan TLS ==================================\n" + echoContent skyBlue "\n================================== Trojan TLS [不推荐] ==================================\n" jq .inbounds[0].settings.clients ${configPath}04_trojan_TCP_inbounds.json | jq -c '.[]' | while read -r user; do local email= email=$(echo "${user}" | jq -r .email) @@ -4722,7 +4728,7 @@ showAccounts() { fi if echo ${currentInstallProtocolType} | grep -q 2; then - echoContent skyBlue "\n================================ Trojan gRPC TLS ================================\n" + echoContent skyBlue "\n================================ Trojan gRPC TLS [仅CDN不推荐] ================================\n" jq .inbounds[0].settings.clients ${configPath}04_trojan_gRPC_inbounds.json | jq -c '.[]' | while read -r user; do local email= email=$(echo "${user}" | jq -r .email) @@ -4740,7 +4746,7 @@ showAccounts() { done fi if echo ${currentInstallProtocolType} | grep -q 6; then - echoContent skyBlue "\n================================ Hysteria TLS ================================\n" + echoContent skyBlue "\n================================ Hysteria2 TLS [推荐] ================================\n" jq -r -c '.inbounds[]|select(.type=="hysteria2")|.users[]' "${singBoxConfigPath}config.json" | while read -r user; do echoContent skyBlue "\n ---> 账号:$(echo "${user}" | jq -r .name)" echo @@ -4752,7 +4758,7 @@ showAccounts() { # VLESS reality vision if echo ${currentInstallProtocolType} | grep -q 7; then show=1 - echoContent skyBlue "============================= VLESS reality_vision ==============================\n" + echoContent skyBlue "============================= VLESS reality_vision [推荐] ==============================\n" jq .inbounds[0].settings.clients ${configPath}07_VLESS_vision_reality_inbounds.json | jq -c '.[]' | while read -r user; do local email= email=$(echo "${user}" | jq -r .email) @@ -4766,7 +4772,7 @@ showAccounts() { # VLESS reality if echo ${currentInstallProtocolType} | grep -q 8; then show=1 - echoContent skyBlue "============================== VLESS reality_gRPC ===============================\n" + echoContent skyBlue "============================== VLESS reality_gRPC [推荐] ===============================\n" jq .inbounds[0].settings.clients ${configPath}08_VLESS_reality_fallback_grpc_inbounds.json | jq -c '.[]' | while read -r user; do local email= email=$(echo "${user}" | jq -r .email) @@ -4778,7 +4784,7 @@ showAccounts() { fi # tuic if echo ${currentInstallProtocolType} | grep -q 9; then - echoContent skyBlue "\n================================ Tuic TLS ================================\n" + echoContent skyBlue "\n================================ Tuic TLS [推荐] ================================\n" jq -r -c '.inbounds[]|select(.type=="tuic")|.users[]' "${singBoxConfigPath}config.json" | while read -r user; do echoContent skyBlue "\n ---> 账号:$(echo "${user}" | jq -r .name)" echo @@ -5759,7 +5765,7 @@ ipv6Routing() { echo "${outbounds}" | jq . >${configPath}10_ipv4_outbounds.json configurationSingBoxRoute add IPv6-out "${domainList}" - addSingBoxOutbound IPv6_out + addSingBoxOutbound IPv6-out echoContent green " ---> 添加成功" elif [[ "${ipv6Status}" == "3" ]]; then @@ -7043,13 +7049,13 @@ customXrayInstall() { echoContent skyBlue "\n========================个性化安装============================" echoContent yellow "VLESS前置,默认安装0,如果只需要安装0,则只选择0即可" echoContent yellow "0.VLESS+TLS_Vision+TCP[推荐]" - echoContent yellow "1.VLESS+TLS+WS[CDN]" - echoContent yellow "2.Trojan+TLS+gRPC[CDN]" - echoContent yellow "3.VMess+TLS+WS[CDN]" - echoContent yellow "4.Trojan+TLS" - echoContent yellow "5.VLESS+TLS+gRPC[CDN]" + echoContent yellow "1.VLESS+TLS+WS[仅CDN推荐]" + echoContent yellow "2.Trojan+TLS+gRPC[仅CDN推荐]" + echoContent yellow "3.VMess+TLS+WS[仅CDN推荐]" + echoContent yellow "4.Trojan+TLS[不推荐]" + echoContent yellow "5.VLESS+TLS+gRPC[仅CDN推荐]" echoContent yellow "7.VLESS+Reality+uTLS+Vision[推荐]" - # echoContent yellow "8.VLESS+Reality+gRPC" + # echoContent yellow "8.VLESS+Reality+gRPC" read -r -p "请选择[多选],[例如:123]:" selectCustomInstallType echoContent skyBlue "--------------------------------------------------------------" if [[ -z ${selectCustomInstallType} ]]; then @@ -8391,7 +8397,7 @@ menu() { cd "$HOME" || exit echoContent red "\n==============================================================" echoContent green "作者:mack-a" - echoContent green "当前版本:v2.11.8" + echoContent green "当前版本:v2.11.9" echoContent green "Github:https://github.com/mack-a/v2ray-agent" echoContent green "描述:八合一共存脚本\c" showInstallStatus