1 2 3 4 5 6 | [root@ipfire cgi-bin]# /etc/init.d/dnsmasq restart Stopping Domain Name Service Proxy... [ OK ] Starting Domain Name Service Proxy... dnsmasq: recompile with HAVE_SCRIPT defined to enable lease-change scripts at line 4 of /etc/dnsmasq.conf [ FAIL ] |
1 2 3 | conf-dir=/etc/dnsmasq.d dhcp-script=/usr/local/bin/dnsmasq-dhcp-wildcards |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | #!/bin/sh tld=.example mode=$1 ip=$2 name=$3$tld filename="/etc/dnsmasq.d/wildcard-dhcp-$name.conf" echo $@ >> /tmp/log if [ "$mode" == add ]; then echo "address=/.$name/$ip/" > "$filename" elif [ "$mode" == del ]; then rm "$filename" fi |