mirror of https://github.com/mack-a/v2ray-agent
parent
5d487ef333
commit
2322e1343b
147
install.sh
147
install.sh
|
@ -4293,39 +4293,39 @@ EOF
|
||||||
rm /etc/v2ray-agent/xray/conf/12_VLESS_XHTTP_inbounds.json >/dev/null 2>&1
|
rm /etc/v2ray-agent/xray/conf/12_VLESS_XHTTP_inbounds.json >/dev/null 2>&1
|
||||||
fi
|
fi
|
||||||
# trojan_grpc
|
# trojan_grpc
|
||||||
if echo "${selectCustomInstallType}" | grep -q ",2," || [[ "$1" == "all" ]]; then
|
# if echo "${selectCustomInstallType}" | grep -q ",2," || [[ "$1" == "all" ]]; then
|
||||||
if ! echo "${selectCustomInstallType}" | grep -q ",5," && [[ -n ${selectCustomInstallType} ]]; then
|
# if ! echo "${selectCustomInstallType}" | grep -q ",5," && [[ -n ${selectCustomInstallType} ]]; then
|
||||||
fallbacksList=${fallbacksList//31302/31304}
|
# fallbacksList=${fallbacksList//31302/31304}
|
||||||
fi
|
# fi
|
||||||
cat <<EOF >/etc/v2ray-agent/xray/conf/04_trojan_gRPC_inbounds.json
|
# cat <<EOF >/etc/v2ray-agent/xray/conf/04_trojan_gRPC_inbounds.json
|
||||||
{
|
#{
|
||||||
"inbounds": [
|
# "inbounds": [
|
||||||
{
|
# {
|
||||||
"port": 31304,
|
# "port": 31304,
|
||||||
"listen": "127.0.0.1",
|
# "listen": "127.0.0.1",
|
||||||
"protocol": "trojan",
|
# "protocol": "trojan",
|
||||||
"tag": "trojangRPCTCP",
|
# "tag": "trojangRPCTCP",
|
||||||
"settings": {
|
# "settings": {
|
||||||
"clients": $(initXrayClients 2),
|
# "clients": $(initXrayClients 2),
|
||||||
"fallbacks": [
|
# "fallbacks": [
|
||||||
{
|
# {
|
||||||
"dest": "31300"
|
# "dest": "31300"
|
||||||
}
|
# }
|
||||||
]
|
# ]
|
||||||
},
|
# },
|
||||||
"streamSettings": {
|
# "streamSettings": {
|
||||||
"network": "grpc",
|
# "network": "grpc",
|
||||||
"grpcSettings": {
|
# "grpcSettings": {
|
||||||
"serviceName": "${customPath}trojangrpc"
|
# "serviceName": "${customPath}trojangrpc"
|
||||||
}
|
# }
|
||||||
}
|
# }
|
||||||
}
|
# }
|
||||||
]
|
# ]
|
||||||
}
|
#}
|
||||||
EOF
|
#EOF
|
||||||
elif [[ -z "$3" ]]; then
|
# elif [[ -z "$3" ]]; then
|
||||||
rm /etc/v2ray-agent/xray/conf/04_trojan_gRPC_inbounds.json >/dev/null 2>&1
|
# rm /etc/v2ray-agent/xray/conf/04_trojan_gRPC_inbounds.json >/dev/null 2>&1
|
||||||
fi
|
# fi
|
||||||
|
|
||||||
# VMess_WS
|
# VMess_WS
|
||||||
if echo "${selectCustomInstallType}" | grep -q ",3," || [[ "$1" == "all" ]]; then
|
if echo "${selectCustomInstallType}" | grep -q ",3," || [[ "$1" == "all" ]]; then
|
||||||
|
@ -4356,33 +4356,33 @@ EOF
|
||||||
elif [[ -z "$3" ]]; then
|
elif [[ -z "$3" ]]; then
|
||||||
rm /etc/v2ray-agent/xray/conf/05_VMess_WS_inbounds.json >/dev/null 2>&1
|
rm /etc/v2ray-agent/xray/conf/05_VMess_WS_inbounds.json >/dev/null 2>&1
|
||||||
fi
|
fi
|
||||||
|
# VLESS_gRPC
|
||||||
if echo "${selectCustomInstallType}" | grep -q ",5," || [[ "$1" == "all" ]]; then
|
# if echo "${selectCustomInstallType}" | grep -q ",5," || [[ "$1" == "all" ]]; then
|
||||||
cat <<EOF >/etc/v2ray-agent/xray/conf/06_VLESS_gRPC_inbounds.json
|
# cat <<EOF >/etc/v2ray-agent/xray/conf/06_VLESS_gRPC_inbounds.json
|
||||||
{
|
#{
|
||||||
"inbounds":[
|
# "inbounds":[
|
||||||
{
|
# {
|
||||||
"port": 31301,
|
# "port": 31301,
|
||||||
"listen": "127.0.0.1",
|
# "listen": "127.0.0.1",
|
||||||
"protocol": "vless",
|
# "protocol": "vless",
|
||||||
"tag":"VLESSGRPC",
|
# "tag":"VLESSGRPC",
|
||||||
"settings": {
|
# "settings": {
|
||||||
"clients": $(initXrayClients 5),
|
# "clients": $(initXrayClients 5),
|
||||||
"decryption": "none"
|
# "decryption": "none"
|
||||||
},
|
# },
|
||||||
"streamSettings": {
|
# "streamSettings": {
|
||||||
"network": "grpc",
|
# "network": "grpc",
|
||||||
"grpcSettings": {
|
# "grpcSettings": {
|
||||||
"serviceName": "${customPath}grpc"
|
# "serviceName": "${customPath}grpc"
|
||||||
}
|
# }
|
||||||
}
|
# }
|
||||||
}
|
# }
|
||||||
]
|
#]
|
||||||
}
|
#}
|
||||||
EOF
|
#EOF
|
||||||
elif [[ -z "$3" ]]; then
|
# elif [[ -z "$3" ]]; then
|
||||||
rm /etc/v2ray-agent/xray/conf/06_VLESS_gRPC_inbounds.json >/dev/null 2>&1
|
# rm /etc/v2ray-agent/xray/conf/06_VLESS_gRPC_inbounds.json >/dev/null 2>&1
|
||||||
fi
|
# fi
|
||||||
|
|
||||||
# VLESS Vision
|
# VLESS Vision
|
||||||
if echo "${selectCustomInstallType}" | grep -q ",0," || [[ "$1" == "all" ]]; then
|
if echo "${selectCustomInstallType}" | grep -q ",0," || [[ "$1" == "all" ]]; then
|
||||||
|
@ -8130,8 +8130,8 @@ customSingBoxInstall() {
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ "${selectCustomInstallType//,/}" =~ ^[0-9]+$ ]]; then
|
if [[ "${selectCustomInstallType//,/}" =~ ^[0-9]+$ ]]; then
|
||||||
unInstallSubscribe
|
|
||||||
readLastInstallationConfig
|
readLastInstallationConfig
|
||||||
|
unInstallSubscribe
|
||||||
totalProgress=9
|
totalProgress=9
|
||||||
installTools 1
|
installTools 1
|
||||||
# 申请tls
|
# 申请tls
|
||||||
|
@ -8165,10 +8165,10 @@ customXrayInstall() {
|
||||||
echoContent yellow "VLESS前置,默认安装0,无域名安装Reality只选择7即可"
|
echoContent yellow "VLESS前置,默认安装0,无域名安装Reality只选择7即可"
|
||||||
echoContent yellow "0.VLESS+TLS_Vision+TCP[推荐]"
|
echoContent yellow "0.VLESS+TLS_Vision+TCP[推荐]"
|
||||||
echoContent yellow "1.VLESS+TLS+WS[仅CDN推荐]"
|
echoContent yellow "1.VLESS+TLS+WS[仅CDN推荐]"
|
||||||
echoContent yellow "2.Trojan+TLS+gRPC[仅CDN推荐]"
|
# echoContent yellow "2.Trojan+TLS+gRPC[仅CDN推荐]"
|
||||||
echoContent yellow "3.VMess+TLS+WS[仅CDN推荐]"
|
echoContent yellow "3.VMess+TLS+WS[仅CDN推荐]"
|
||||||
echoContent yellow "4.Trojan+TLS[不推荐]"
|
echoContent yellow "4.Trojan+TLS[不推荐]"
|
||||||
echoContent yellow "5.VLESS+TLS+gRPC[仅CDN推荐]"
|
# echoContent yellow "5.VLESS+TLS+gRPC[仅CDN推荐]"
|
||||||
echoContent yellow "7.VLESS+Reality+uTLS+Vision[推荐]"
|
echoContent yellow "7.VLESS+Reality+uTLS+Vision[推荐]"
|
||||||
# echoContent yellow "8.VLESS+Reality+gRPC"
|
# echoContent yellow "8.VLESS+Reality+gRPC"
|
||||||
echoContent yellow "12.VLESS+XHTTP+TLS"
|
echoContent yellow "12.VLESS+XHTTP+TLS"
|
||||||
|
@ -8193,10 +8193,6 @@ customXrayInstall() {
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# if [[ "${selectCustomInstallType: -1}" != "," ]]; then
|
|
||||||
# selectCustomInstallType="${selectCustomInstallType},"
|
|
||||||
# fi
|
|
||||||
#
|
|
||||||
if [[ "${selectCustomInstallType:0:1}" != "," ]]; then
|
if [[ "${selectCustomInstallType:0:1}" != "," ]]; then
|
||||||
selectCustomInstallType=",${selectCustomInstallType},"
|
selectCustomInstallType=",${selectCustomInstallType},"
|
||||||
fi
|
fi
|
||||||
|
@ -8337,6 +8333,7 @@ xrayCoreInstall() {
|
||||||
# sing-box 全部安装
|
# sing-box 全部安装
|
||||||
singBoxInstall() {
|
singBoxInstall() {
|
||||||
readLastInstallationConfig
|
readLastInstallationConfig
|
||||||
|
unInstallSubscribe
|
||||||
checkBTPanel
|
checkBTPanel
|
||||||
check1Panel
|
check1Panel
|
||||||
selectCustomInstallType=
|
selectCustomInstallType=
|
||||||
|
@ -8364,9 +8361,9 @@ singBoxInstall() {
|
||||||
installCronTLS 8
|
installCronTLS 8
|
||||||
|
|
||||||
handleSingBox stop
|
handleSingBox stop
|
||||||
sleep 2
|
|
||||||
handleSingBox start
|
handleSingBox start
|
||||||
unInstallSubscribe
|
handleNginx stop
|
||||||
|
handleNginx start
|
||||||
# 生成账号
|
# 生成账号
|
||||||
showAccounts 9
|
showAccounts 9
|
||||||
}
|
}
|
||||||
|
@ -9396,14 +9393,19 @@ initRealityClientServersName() {
|
||||||
installSubscribe
|
installSubscribe
|
||||||
readNginxSubscribe
|
readNginxSubscribe
|
||||||
realityDomainPort="${subscribePort}"
|
realityDomainPort="${subscribePort}"
|
||||||
|
else
|
||||||
|
realityDomainPort="${subscribePort}"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
if [[ "${selectCoreType}" == "2" ]]; then
|
||||||
if [[ "${selectCoreType}" == "2" && -z "${subscribePort}" ]]; then
|
if [[ -z "${subscribePort}" ]]; then
|
||||||
echo
|
echo
|
||||||
installSubscribe
|
installSubscribe
|
||||||
readNginxSubscribe
|
readNginxSubscribe
|
||||||
realityDomainPort="${subscribePort}"
|
realityDomainPort="${subscribePort}"
|
||||||
|
else
|
||||||
|
realityDomainPort="${subscribePort}"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
@ -9537,7 +9539,6 @@ xrayCoreRealityInstall() {
|
||||||
sleep 2
|
sleep 2
|
||||||
# 启动
|
# 启动
|
||||||
handleXray start
|
handleXray start
|
||||||
# unInstallSubscribe
|
|
||||||
# 生成账号
|
# 生成账号
|
||||||
showAccounts 8
|
showAccounts 8
|
||||||
}
|
}
|
||||||
|
@ -9769,7 +9770,7 @@ menu() {
|
||||||
cd "$HOME" || exit
|
cd "$HOME" || exit
|
||||||
echoContent red "\n=============================================================="
|
echoContent red "\n=============================================================="
|
||||||
echoContent green "作者:mack-a"
|
echoContent green "作者:mack-a"
|
||||||
echoContent green "当前版本:v3.4.4"
|
echoContent green "当前版本:v3.4.5"
|
||||||
echoContent green "Github:https://github.com/mack-a/v2ray-agent"
|
echoContent green "Github:https://github.com/mack-a/v2ray-agent"
|
||||||
echoContent green "描述:八合一共存脚本\c"
|
echoContent green "描述:八合一共存脚本\c"
|
||||||
showInstallStatus
|
showInstallStatus
|
||||||
|
|
Loading…
Reference in New Issue