File tree Expand file tree Collapse file tree 3 files changed +6
-12
lines changed
Expand file tree Collapse file tree 3 files changed +6
-12
lines changed Original file line number Diff line number Diff line change @@ -1132,12 +1132,10 @@ $VESTA/bin/v-update-sys-ip
11321132ip=$( ip addr| grep ' inet ' | grep global| head -n1| awk ' {print $2}' | cut -f1 -d/)
11331133
11341134# Get public ip
1135- pub_ip=$( curl vestacp.com/what-is-my-ip/)
1135+ pub_ip=$( curl -s vestacp.com/what-is-my-ip/)
11361136if [ ! -z " $pub_ip " ] && [ " $pub_ip " != " $ip " ]; then
11371137 $VESTA /bin/v-change-sys-ip-nat $ip $pub_ip
1138- fi
1139- if [ -z " $pub_ip " ]; then
1140- ip=$main_ip
1138+ ip=$pub_ip
11411139fi
11421140
11431141# Firewall configuration
Original file line number Diff line number Diff line change @@ -1202,12 +1202,10 @@ $VESTA/bin/v-update-sys-ip
12021202ip=$( ip addr| grep ' inet ' | grep global| head -n1| awk ' {print $2}' | cut -f1 -d/)
12031203
12041204# Get public ip
1205- pub_ip=$( curl vestacp.com/what-is-my-ip/)
1205+ pub_ip=$( curl -s vestacp.com/what-is-my-ip/)
12061206if [ ! -z " $pub_ip " ] && [ " $pub_ip " != " $ip " ]; then
12071207 $VESTA /bin/v-change-sys-ip-nat $ip $pub_ip
1208- fi
1209- if [ -z " $pub_ip " ]; then
1210- ip=$main_ip
1208+ ip=$pub_ip
12111209fi
12121210
12131211# Firewall configuration
Original file line number Diff line number Diff line change @@ -1121,12 +1121,10 @@ $VESTA/bin/v-update-sys-ip
11211121ip=$( ip addr| grep ' inet ' | grep global| head -n1| awk ' {print $2}' | cut -f1 -d/)
11221122
11231123# Get public ip
1124- pub_ip=$( curl vestacp.com/what-is-my-ip/)
1124+ pub_ip=$( curl -s vestacp.com/what-is-my-ip/)
11251125if [ ! -z " $pub_ip " ] && [ " $pub_ip " != " $ip " ]; then
11261126 $VESTA /bin/v-change-sys-ip-nat $ip $pub_ip
1127- fi
1128- if [ -z " $pub_ip " ]; then
1129- ip=$main_ip
1127+ ip=$pub_ip
11301128fi
11311129
11321130# Firewall configuration
You can’t perform that action at this time.
0 commit comments