ledgetech / ledgetech/lua-resty-http
if no resolver is specified, what is the default DNS resolution behavior
Nobody has claimed this yet.
- Dominant language
- Lua
- Stars
- 2.1k
- Forks
- 630
- PR merge metrics
- No merged PRs in 30d
Description
I'd like to ask, when using openresty http request_uri, if no resolver is specified, what is the default DNS resolution behavior? My Nginx service is running inside Docker, and I added a host entry in the Docker container's /etc/hosts file. However, the domain name fails to resolve during the http.lua connect call. So I want to know: is the default domain name resolution behavior only using /etc/resolv.conf and not using /etc/hosts?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue names the http.lua connect call and Docker's /etc/hosts and /etc/resolv.conf; start by tracing how hostname resolution is invoked when no resolver is configured. Check the relevant OpenResty or ngx_lua behavior, then document whether /etc/hosts is consulted and clarify the conditions under which the reported failure occurs.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- docker, lua, nginx
- Domain
- documentation, networking
- Issue type
- Documentation
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100