Use an alternative DNS server
williamdes opened this issue · comments
Hi,
It would be awesome to be able to use a defined DNS name server.
Because for my specific uses my servers can query smtp.domain.tld internally and it returns an internal IP.
But from the outside world it gives the public IP.
Either allow unsecure DNS results, but thats a bit sad:
error securely resolving "mx1.mails.domain.tld"
not AD set for results from 10.10.18.1:53 for "mx1.mails.domain.tld."/AAAA query, skipping any remaining resolvers
not AD set for results from 10.10.18.1:53 for "mx1.mails.domain.tld."/A query, skipping any remaining resolvers
no results found
Or support using another resolver. That could allow the user to do checks with different resolvers to monitor if results do not differ
PS: this project is awesome, and having .deb releases is great !
It's probably under-documented, but you can set DNS_RESOLVER
in the process environment, to query using that resolver. Comma-separated list, optional whitespace after the commas.
It was only mentioned in the "Access Needed" section, oops.
I've updated the README for now, but will leave this ticket open because this should probably be a flag for discoverability, instead of just the env var. I think that at the time, my mind was thinking in terms of $RES_OPTIONS
and historical libc env vars for overrides.
Thank you so much for your quick answer !