Clone this repository to /srv/docker/isc-dhcp-server
.
Create a dhcpd/dhcpd.conf
file. Each subnet's IP address will
automatically be matched to the local network interfaces. Any
subnet not specified will not listen on the corresponding interface.
This file can actually be created after running docker-compose
,
because the restart policy is set for always
.
docker-compose up --build
If you run the container manually, be sure to set the network to host
, so
that it can respond to link layer frames.
docker run -dt --name dhcpd \
-v /srv/docker/isc-dhcp-server/dhcpd:/data \
--network=host -p 67/udp \
dhcpd