From 7734b41eb1e03f1c96c99b755cad77c8f91c31ca Mon Sep 17 00:00:00 2001 From: yeahwu Date: Fri, 15 Mar 2024 23:27:40 +0800 Subject: [PATCH] Change to random port --- hy2.sh | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/hy2.sh b/hy2.sh index 90d450f..c4d04ba 100644 --- a/hy2.sh +++ b/hy2.sh @@ -9,11 +9,7 @@ fi timedatectl set-timezone Asia/Shanghai hyPasswd=$(cat /proc/sys/kernel/random/uuid) - -read -t 15 -p "回车或等待15秒为默认端口443,或者自定义端口请输入(1-65535):" getPort -if [ -z $getPort ];then - getPort=443 -fi +getPort=$(shuf -i 2000-65000 -n 1) getIP(){ local serverIP=