Open jimparis opened 10 months ago
Actually this seems straightforward to support: #869
# podman network rm lan
lan
# podman network create --disable-dns --driver bridge --interface-name brint --ipam-driver dhcp lan
lan
# podman run -it --rm --network=lan alpine ip addr show eth0
2: eth0@if34: <BROADCAST,MULTICAST,UP,LOWER_UP,M-DOWN> mtu 1500 qdisc noqueue state UP qlen 1000
link/ether d6:7e:53:56:2b:27 brd ff:ff:ff:ff:ff:ff
inet 10.0.103.178/16 brd 10.0.255.255 scope global eth0
valid_lft forever preferred_lft forever
inet6 fe80::d47e:53ff:fe56:2b27/64 scope link tentative
valid_lft forever preferred_lft forever
I created https://github.com/containers/netavark/issues/1090 to address the prereqs to this functionality and preferred approach, since those aren't DHCP-specific.
With podman version 4.7.2, netavark version 1.8.0:
macvlan
driver works with DHCP:(note assigned 10.0.103.174 address there)
But
bridge
does not:Is this configuration supportable?
(For my setup, I need
bridge
instead ofmacvlan
so that the host can communicate with the container too. I can work around it with--cap-add NET_ADMIN,NET_RAW
and runningudhcpc
inside the container, but would prefer to avoid that if possible.)