main/dnsmasq: init: add extra setup command hook
for cases other than bridges dnsmasq might need some extra configuration step before starting
Tested with conf.d value, used for NetworkManager (if it's slow to start it won't have time to create required dir for resolv-file, nor setup lo if bind-interfaces is set):
setup_command=extra_setup
extra_setup() {
mkdir -p /run/NetworkManager
ip a add 127.0.0.1/8 dev lo >/dev/null 2>&1
ip a add ::1/128 dev lo >/dev/null 2>&1
}
Cc @smcavoy @craftyguy as that might suppleant #13000 (closed) work if they use it that way with nm dns=none, that's been working well enough for me. It's technically equivalent with resolv-file=/run/NetworkManager/no-stub-resolv.conf
as long as you don't need split dns
Edited by Dominique Martinet