Local DNS set from UI only works periodically

I'm not sure how to handle those things in docker, but on bare metal you can add a file in /etc/dnsmasq.d/ and specify a particular domain and to which server it should be forwarded.

See the -S, --local, --server= sectin here

https://thekelleys.org.uk/dnsmasq/docs/dnsmasq-man.html

and here for an example