mirror of
https://github.com/Ysurac/openmptcprouter-feeds.git
synced 2025-02-12 18:41:51 +00:00
Really pi-hole
This commit is contained in:
parent
814a64a4ba
commit
1fced47334
1 changed files with 8 additions and 4 deletions
|
@ -198,7 +198,8 @@ _get_vps_config() {
|
|||
fi
|
||||
if [ "$pihole" = "true" ]; then
|
||||
uci -q batch <<-EOF >/dev/null
|
||||
set dhcp.@dnsmasq[0].server="$host_ip#53"
|
||||
delete dhcp.@dnsmasq[0].server
|
||||
add_list dhcp.@dnsmasq[0].server="$host_ip#53"
|
||||
set dhcp.@dnsmasq[0].rebind_protection='0'
|
||||
commit dhcp
|
||||
EOF
|
||||
|
@ -240,7 +241,8 @@ _get_vps_config() {
|
|||
fi
|
||||
if [ "$pihole" = "true" ]; then
|
||||
uci -q batch <<-EOF >/dev/null
|
||||
set dhcp.@dnsmasq[0].server="$host_ip#53"
|
||||
delete dhcp.@dnsmasq[0].server
|
||||
add_list dhcp.@dnsmasq[0].server="$host_ip#53"
|
||||
set dhcp.@dnsmasq[0].rebind_protection='0'
|
||||
commit dhcp
|
||||
EOF
|
||||
|
@ -251,7 +253,8 @@ _get_vps_config() {
|
|||
if [ "$pihole" = "true" ]; then
|
||||
host_ip="$(echo "$vps_config" | jsonfilter -q -e '@.openvpn.host_ip')"
|
||||
uci -q batch <<-EOF >/dev/null
|
||||
set dhcp.@dnsmasq[0].server="$host_ip#53"
|
||||
delete dhcp.@dnsmasq[0].server
|
||||
add_list dhcp.@dnsmasq[0].server="$host_ip#53"
|
||||
set dhcp.@dnsmasq[0].rebind_protection='0'
|
||||
commit dhcp
|
||||
EOF
|
||||
|
@ -262,7 +265,8 @@ _get_vps_config() {
|
|||
if [ "$pihole" = "true" ]; then
|
||||
host_ip="$(echo "$vps_config" | jsonfilter -q -e '@.mlvpn.host_ip')"
|
||||
uci -q batch <<-EOF >/dev/null
|
||||
set dhcp.@dnsmasq[0].server="$host_ip#53"
|
||||
delete dhcp.@dnsmasq[0].server
|
||||
add_list dhcp.@dnsmasq[0].server="$host_ip#53"
|
||||
set dhcp.@dnsmasq[0].rebind_protection='0'
|
||||
commit dhcp
|
||||
EOF
|
||||
|
|
Loading…
Reference in a new issue