1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter-feeds.git synced 2025-02-15 03:51:51 +00:00

Set servers if empty in dnsmasq

This commit is contained in:
Ycarus (Yannick Chabanois) 2025-02-14 15:14:27 +01:00
parent 3720e9b1a5
commit c143a6bdc2

View file

@ -53,6 +53,15 @@ if [ -f /etc/init.d/dnsmasq ]; then
fi
fi
if [ -f /etc/init.d/dnsmasq ] && [ -z "$(uci -q get dhcp.@dnsmasq[0].server)" ]; then
uci -q batch <<-EOF >/dev/null
add_list dhcp.dnsmasq1.server='127.0.0.1#5353'
add_list dhcp.dnsmasq1.server='/lan/'
add_list dhcp.dnsmasq1.server='/use-application-dns.net/'
commit dhcp
EOF
fi
if [ "$(pgrep openvpn)" = "" ] && [ -f /etc/init.d/openvpn ]; then
openvpn_enable=0
openvpn_enabled() {