This commit is contained in:
BoHung Chiu 2022-09-15 16:11:13 +08:00
parent 5543796f1e
commit 8c87cdb600
1 changed files with 1 additions and 2 deletions

View File

@ -228,8 +228,7 @@ create)
echo "-----------------------------------------------------"
echo "$site_name is ready"
echo "Path: $ORBIT_SITES/$site_name"
interface_name=`ip route get 8.8.8.8|xargs|awk '{print $5}'`;
local_ip=`ip a|grep "$interface_name" | grep -ohP '(?<=inet ).*(?=/24)'|sed 's/\s*$//g'|xargs|awk '{print $1}'`
local_ip=`ip route get 8.8.8.8|xargs|awk '{print $7}'`;
echo http://$local_ip:$PORT
echo "-----------------------------------------------------"