Add an OPTIONS configuration variable in order to make it possible to
pass custom extra options to dhcpd.
Signed-off-by: Benoît Thébaudeau <benoit@wsystem.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
# Separate multiple interfaces with spaces, e.g. "eth0 eth1".
INTERFACES=""
+# Additional options that are passed to the DHCP server daemon?
+OPTIONS=""
+
NAME="dhcpd"
DAEMON="/usr/sbin/${NAME}"
CFG_FILE="/etc/default/${NAME}"
printf "Starting DHCP server: "
test -d /var/lib/dhcp/ || mkdir -p /var/lib/dhcp/
test -f /var/lib/dhcp/dhcpd.leases || touch /var/lib/dhcp/dhcpd.leases
- start-stop-daemon -S -x ${DAEMON} -- -q $INTERFACES
+ start-stop-daemon -S -x ${DAEMON} -- -q $OPTIONS $INTERFACES
[ $? = 0 ] && echo "OK" || echo "FAIL"
;;
stop)