mirror of https://github.com/wulabing/Xray_onekey
parent
d92610983e
commit
3c334a6579
31
install.sh
31
install.sh
|
@ -27,7 +27,7 @@ OK="${Green}[OK]${Font}"
|
||||||
ERROR="${Red}[ERROR]${Font}"
|
ERROR="${Red}[ERROR]${Font}"
|
||||||
|
|
||||||
# 变量
|
# 变量
|
||||||
shell_version="1.2.14"
|
shell_version="1.2.15"
|
||||||
github_branch="main"
|
github_branch="main"
|
||||||
xray_conf_dir="/usr/local/etc/xray"
|
xray_conf_dir="/usr/local/etc/xray"
|
||||||
website_dir="/www/xray_web/"
|
website_dir="/www/xray_web/"
|
||||||
|
@ -255,7 +255,6 @@ function update_sh() {
|
||||||
exit 0
|
exit 0
|
||||||
;;
|
;;
|
||||||
*) ;;
|
*) ;;
|
||||||
|
|
||||||
esac
|
esac
|
||||||
else
|
else
|
||||||
print_ok "当前版本为最新版本"
|
print_ok "当前版本为最新版本"
|
||||||
|
@ -459,12 +458,27 @@ function configure_web() {
|
||||||
function xray_uninstall() {
|
function xray_uninstall() {
|
||||||
curl -L https://github.com/XTLS/Xray-install/raw/main/install-release.sh | bash -s -- remove --purge
|
curl -L https://github.com/XTLS/Xray-install/raw/main/install-release.sh | bash -s -- remove --purge
|
||||||
rm -rf $website_dir
|
rm -rf $website_dir
|
||||||
if [[ "${ID}" == "centos" ]]; then
|
read -rp "是否卸载nginx" uninstall_nginx
|
||||||
yum remove nginx -y
|
case $uninstall_nginx in
|
||||||
rm -rf /etc/nginx
|
[yY][eE][sS] | [yY])
|
||||||
else
|
if [[ "${ID}" == "centos" ]]; then
|
||||||
apt purge nginx -y
|
yum remove nginx -y
|
||||||
fi
|
rm -rf /etc/nginx
|
||||||
|
else
|
||||||
|
apt purge nginx -y
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
*) ;;
|
||||||
|
esac
|
||||||
|
read -rp "是否卸载acme.sh" uninstall_acme
|
||||||
|
case $uninstall_acme in
|
||||||
|
[yY][eE][sS] | [yY])
|
||||||
|
/root/.acme.sh/acme.sh --uninstall
|
||||||
|
rm -rf /root/.acme.sh
|
||||||
|
rm -rf /ssl/
|
||||||
|
;;
|
||||||
|
*) ;;
|
||||||
|
esac
|
||||||
print_ok "卸载完成"
|
print_ok "卸载完成"
|
||||||
exit 0
|
exit 0
|
||||||
}
|
}
|
||||||
|
@ -715,6 +729,7 @@ menu() {
|
||||||
mtproxy_sh
|
mtproxy_sh
|
||||||
;;
|
;;
|
||||||
33)
|
33)
|
||||||
|
source '/etc/os-release'
|
||||||
xray_uninstall
|
xray_uninstall
|
||||||
;;
|
;;
|
||||||
34)
|
34)
|
||||||
|
|
Loading…
Reference in New Issue