Update InstallNET.sh

This commit is contained in:
Molly Lau 2023-08-23 23:15:49 +09:00 committed by GitHub
parent bc33266bcc
commit d4ffa79bb2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -2985,6 +2985,7 @@ if [ -z "$interfaceSelect" ]; then
# Some cloud providers using the second or further order back of interface adapter like "eth1" to config public networking usually and we don't know what's role of "eth0".
[[ "$interfacesNum" -ge "2" ]] && {
if [[ "$IPStackType" == "IPv6Stack" ]]; then
# Approximately equal "=~" to "eth..." is for the redirected situation, "device order" is on the contrary for an un-redirected example.
[[ "$interface6" =~ "eth" && `echo "$interface6" | grep -o '[0-9]'` != "0" ]] || [[ "$interface6DeviceOrder" != "0" ]] && {
interfaceSelect="$interface6"
}