Subject: Request to allow configuring path for resolv.conf file

Request to allow configuring path for resolv.conf file

From: Sarat Chandra Addepalli <sarat.addepalli_at_paytm.com>
Date: Fri, 31 Aug 2018 23:04:30 +0530

Hi Team!

I'm interested in adding configurability, for the path for the resolv.conf
file.

As I understand, currently for *nix systems it is currently #define d to
/etc/resolv.conf in ares_private.h,
and yet ares_init.c does try for a couple more options if this fails:
 - /etc/nsswitch.conf
 - /etc/host.conf
 - /etc/svc.conf

I also see that "Inet$Resolvers" is used as a system variable on RISC_OS,
to detect the same.

I would like to add functionality to configure the resolv.conf file's path,
preferably via
an environment variable (say CARES_RESOLVE_CONF_PATH or something similar).

I have raised an issue on GitHub at
https://github.com/c-ares/c-ares/issues/220 for this,
but I understand that maintainers might be more active on this mailing
list, so I would like
to know if such an approach is welcome or not.

Any thoughts?

As I've noted in the GitHub issue, the primary motivation here was to test
the functionality of
NodeJS's dns module, which internally uses c-ares. I would like to test
behaviour with different
contents for the resolv.conf file.

Thanks and regards,
Sarat Addepalli
sarat.addepalli_at_paytm.com
+91 8447699863
Received on 2018-08-31