Update 'DynDNS/install.sh'
This commit is contained in:
parent
393a262111
commit
7392f170c8
|
@ -12,13 +12,11 @@ domain=$(uci get dhcp.@dnsmasq[0].domain)
|
||||||
sed -i "s/.lan/.$domain/gi" /root/dyndns/dyndns.lua
|
sed -i "s/.lan/.$domain/gi" /root/dyndns/dyndns.lua
|
||||||
|
|
||||||
# Create dhcp script
|
# Create dhcp script
|
||||||
echo "cd /root/dyndns/ && lua dyndns.lua" > /root/dyndns/dyndns.sh
|
echo "cd /root/dyndns/ && lua dyndns.lua" > /etc/hotplug.d/dhcp/99-dyndns
|
||||||
|
|
||||||
# Allow execution
|
# Allow execution
|
||||||
chmod +x /root/dyndns/*.*
|
chmod 755 /etc/hotplug.d/dhcp/99-dyndns
|
||||||
|
chmod +x /etc/hotplug.d/dhcp/99-dyndns
|
||||||
# Add dhcpscript to the config
|
|
||||||
uci set dhcp.@dnsmasq[0].dhcpscript='/root/dyndns/dyndns.sh'
|
|
||||||
|
|
||||||
# Add addnlist to the config
|
# Add addnlist to the config
|
||||||
uci set dhcp.@dnsmasq[0].addnhosts='/tmp/dyndns'
|
uci set dhcp.@dnsmasq[0].addnhosts='/tmp/dyndns'
|
||||||
|
|
Loading…
Reference in a new issue