mirror of
https://github.com/vdsm/virtual-dsm.git
synced 2026-02-21 18:37:23 +08:00
feat: Mimic container IP
This commit is contained in:
parent
85ee542fc5
commit
68943403fb
@ -371,7 +371,14 @@ configureNAT() {
|
||||
fi
|
||||
fi
|
||||
|
||||
local ip="172.30.0.2"
|
||||
local ip base
|
||||
base=$(echo "$IP" | sed -r 's/([^.]*.){2}//')
|
||||
if [[ "$IP" != "172.30."* ]]; then
|
||||
ip="172.30.$base"
|
||||
else
|
||||
ip="172.31.$base"
|
||||
fi
|
||||
|
||||
[ -n "$VM_NET_IP" ] && ip="$VM_NET_IP"
|
||||
|
||||
local gateway=""
|
||||
|
||||
Loading…
Reference in New Issue
Block a user