unifi-utilities / unifios-utilities

A collection of enhancements for UnifiOS based devices
GNU General Public License v3.0
3.84k stars 415 forks source link

Help needed: customize default dnsmasq config #207

Open nicx opened 2 years ago

nicx commented 2 years ago

Hey, I hope its ok when I am asking here for help, I just didn't find the right place for support/help questions. If not, just close this "issue".

I have installed the udm-utilities with on_boot_script for igmproxy, which is running just great :)

Now I want to change a dnsmasq default configuration and I just don't know how to do that. I want to change the dnsmasq option from "all-servers" to "strict-order". This option is configured automatically in the file /run/dnsmasq.conf.d/dns.conf and it looks like this:

#
# Generated automatically by ubios-udapi-server
#

# Configuration of DNS Forwarder
# Never forward plain names (without a dot or domain part)
domain-needed
# Never forward addresses in the non-routed address spaces.
bogus-priv
cache-size=10000
dns-loop-detect
dns-forward-max=1000
resolv-file=/etc/resolv.dnsmasq
all-servers
interface=br0
# Add resolution support to dnsfilter.
interface=dnsfilter
host-record=unifi.netbag.de,unifi,192.168.1.1
host-record=setup.ui.com,192.168.1.1

Is it "safe" just to write another onboot script which replaces this option in the original file an do a dnsmasq restart afterwards? or is there any other better solution?

Thanks in advance for any help :)

zerog2k commented 2 years ago

not sure if this is helpful https://github.com/boostchicken/udm-utilities/discussions/137