diff --git a/src/scripts/create_ap b/src/scripts/create_ap index 3ee3440..ea93d1d 100755 --- a/src/scripts/create_ap +++ b/src/scripts/create_ap @@ -1802,7 +1802,13 @@ EOF [[ -n "$MTU" ]] && echo "dhcp-option-force=option:mtu,${MTU}" >> $CONFDIR/dnsmasq.conf [[ $ETC_HOSTS -eq 0 ]] && echo no-hosts >> $CONFDIR/dnsmasq.conf [[ -n "$ADDN_HOSTS" ]] && echo "addn-hosts=${ADDN_HOSTS}" >> $CONFDIR/dnsmasq.conf - [[ -n "$DHCP_HOSTS" ]] && echo $DHCP_HOSTS >> $CONFDIR/dnsmaq.conf + if [[ -n "$DHCP_HOSTS" ]]; then + for HOST in $DHCP_HOSTS; do + echo "dhcp-host=${HOST}" >> $CONFDIR/dnsmasq.conf + done + fi + + if [[ -n "$DNS_LOGFILE" ]]; then cat << EOF >> $CONFDIR/dnsmasq.conf log-queries diff --git a/src/scripts/create_ap.conf b/src/scripts/create_ap.conf index f57da55..3921382 100644 --- a/src/scripts/create_ap.conf +++ b/src/scripts/create_ap.conf @@ -27,5 +27,5 @@ INTERNET_IFACE=eth0 SSID=MyAccessPoint PASSPHRASE=12345678 USE_PSK=0 -DHCP_HOSTS="dhcp-host=foo,bar\ndhcp-host=bar,foo" +DHCP_HOSTS=