diff --git a/install.sh b/install.sh index ecf79ad..cabef02 100644 --- a/install.sh +++ b/install.sh @@ -356,9 +356,17 @@ readNginxSubscribe() { if [[ -f "${nginxConfigPath}subscribe.conf" ]]; then if grep -q "sing-box" "${nginxConfigPath}subscribe.conf"; then subscribePort=$(grep "listen" "${nginxConfigPath}subscribe.conf" | awk '{print $2}') - if ! grep "listen" "${nginxConfigPath}subscribe.conf" | grep -q "ssl"; then - subscribeType="http" + subscribeDomain=$(grep "server_name" "${nginxConfigPath}subscribe.conf" | awk '{print $2}') + subscribeDomain=${subscribeDomain//;/} + if [[ "${subscribeDomain}" != "${currentHost}" ]]; then + subscribePort= + subscribeType= + else + if ! grep "listen" "${nginxConfigPath}subscribe.conf" | grep -q "ssl"; then + subscribeType="http" + fi fi + fi fi } @@ -9392,7 +9400,7 @@ menu() { cd "$HOME" || exit echoContent red "\n==============================================================" echoContent green "作者:mack-a" - echoContent green "当前版本:v3.3.5" + echoContent green "当前版本:v3.3.6" echoContent green "Github:https://github.com/mack-a/v2ray-agent" echoContent green "描述:八合一共存脚本\c" showInstallStatus