mirror of
https://github.com/vdsm/virtual-dsm.git
synced 2025-06-01 02:07:20 +08:00
feat: Enable IPv6 support for user-mode container networking (#983)
This commit is contained in:
parent
d5805b4e08
commit
631a558a9f
@ -176,7 +176,11 @@ getHostPorts() {
|
||||
|
||||
configureUser() {
|
||||
|
||||
NET_OPTS="-netdev user,id=hostnet0,host=${VM_NET_IP%.*}.1,net=${VM_NET_IP%.*}.0/24,dhcpstart=$VM_NET_IP,hostname=$VM_NET_HOST"
|
||||
if [ -z "$IP6" ]; then
|
||||
NET_OPTS="-netdev user,id=hostnet0,host=${VM_NET_IP%.*}.1,net=${VM_NET_IP%.*}.0/24,dhcpstart=$VM_NET_IP,hostname=$VM_NET_HOST"
|
||||
else
|
||||
NET_OPTS="-netdev user,id=hostnet0,ipv4=on,host=${VM_NET_IP%.*}.1,net=${VM_NET_IP%.*}.0/24,dhcpstart=$VM_NET_IP,ipv6=on,hostname=$VM_NET_HOST"
|
||||
fi
|
||||
|
||||
local forward
|
||||
forward=$(getUserPorts "$USER_PORTS")
|
||||
|
Loading…
x
Reference in New Issue
Block a user