diff mbox

[OpenWrt-Devel] dnsmasq: enable pxe-prompt, pxe-service config options

Message ID CA+e1LURLSgy==h-Kda5u=Lji3CNZK=JFe-uZecbGcOhF9rODTA@mail.gmail.com
State Accepted
Headers show

Commit Message

Derek LaHousse Feb. 6, 2015, 7:46 p.m. UTC
DNSMASQ has the ability to provide a menu to a pxeboot system, using
the --pxe-prompt and --pxe-service configuration options.  The current
init.d script converting the "dhcp" file to "dnsmasq.conf" does not
find these options, but they are supported.  This patch thus enables
the options.

Signed-off-by: Derek LaHousse <dlahouss@mtu.edu>
---

openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
diff mbox

Patch

diff --git a/package/network/services/dnsmasq/files/dnsmasq.init
b/package/network/services/dnsmasq/files/dnsmasq.init
index 942acd7..9a9f0fd 100644
--- a/package/network/services/dnsmasq/files/dnsmasq.init
+++ b/package/network/services/dnsmasq/files/dnsmasq.init
@@ -103,6 +103,10 @@  append_bogusnxdomain() {
     xappend "--bogus-nxdomain=$1"
 }

+append_pxe_service() {
+    xappend "--pxe-service=$1"
+}
+
 dnsmasq() {
     local cfg="$1"
     append_bool "$cfg" authoritative "--dhcp-authoritative"
@@ -144,6 +148,8 @@  dnsmasq() {
     append_parm "$cfg" "tftp_root" "--tftp-root"
     append_parm "$cfg" "dhcp_boot" "--dhcp-boot"
     append_parm "$cfg" "local_ttl" "--local-ttl"
+    append_parm "$cfg" "pxe_prompt" "--pxe-prompt"
+    config_list_foreach "$cfg" "pxe_service" append_pxe_service

     config_get DOMAIN "$cfg" domain
_______________________________________________