Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

support resolver by default #19

Open
terryzwt opened this issue Aug 5, 2024 · 3 comments
Open

support resolver by default #19

terryzwt opened this issue Aug 5, 2024 · 3 comments

Comments

@terryzwt
Copy link
Contributor

terryzwt commented Aug 5, 2024

I have a similar problem like below post:
https://www.emmanuelgautier.com/blog/nginx-docker-dns-resolution

After add the resolver 127.0.0.11;, problem resolved.

@terryzwt
Copy link
Contributor Author

terryzwt commented Aug 7, 2024

I think it's better to add an environment: NGINX_RESOLVER to set up the resolver manually.
For example, if I run this image in k8s, the resolver should like this:
resolver kube-dns.kube-system.svc.cluster.local;

ref: https://serverfault.com/questions/638822/nginx-resolver-address-from-etc-resolv-conf

@tiredofit
Copy link
Owner

I agree, if the user wishes to use this environment variable it should be customizable. I see that you have put some time into a PR to support this. I can review tomorrow and see what needs to done to support a single or multiple resolvers to solve this issue..

@tiredofit
Copy link
Owner

I reworked your PR into 6.5.0 62b4ad7

Have a peek and see if this works for you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants