Closed blop closed 3 years ago
You can also add a docker-compose example like :
networks:
my-dhcp-net:
driver: ghcr.io/devplayer0/docker-net-dhcp:release-linux-amd64
driver_opts:
bridge: "my-bridge"
lease_timeout: "60s"
ipam:
driver: "null"
Hello!
For some reason I had to perform the following setting in order to have the DHCP client working. sysctl -w net.bridge.bridge-nf-call-iptables=0
Otherwise I kept having the following error : NetworkDriver.CreateEndpoint: failed to get initial IP address via DHCP: context deadline exceeded.
;-)
Hmmm perhaps this is something to do with the FORWARD
policy in iptables
being set to DROP
by default? I'm not too familiar with this sysctl
. If it's set to 1
by default Docker may expect this for its own built-in networking. I didn't run into this issue myself, can you check your iptables
config? There's a minor note in the README about adding a FORWARD
rule over the bridge, perhaps this could also solve your problem?
Hello!
For some reason I had to perform the following setting in order to have the DHCP client working. sysctl -w net.bridge.bridge-nf-call-iptables=0
Otherwise I kept having the following error : NetworkDriver.CreateEndpoint: failed to get initial IP address via DHCP: context deadline exceeded.
;-)