see No mdns support in snaps (should core have a modified nsswitch.conf ?)
as long as this is not fixed, you can hack around it via a wrapper script like i do in: