Summary
The compiled OpenCode binary (Bun) ignores NODE_OPTIONS=--dns-result-order=ipv4first. It also often ignores NO_PROXY when HTTP_PROXY/ALL_PROXY are set, so loopback HTTP backends get sent through CONNECT.
Repro
- Dual-stack DNS where AAAA is unusable and A works.
- NODE_OPTIONS=--dns-result-order=ipv4first opencode run against https://gateway.example/v1.
- Alternatively set HTTPS_PROXY=http://127.0.0.1:PORT, NO_PROXY=127.0.0.1, HTTP_PROXY/ALL_PROXY to the same proxy, and call http://127.0.0.1:OTHER/v1.
Actual
Compiled binary still uses AAAA (or sends loopback through CONNECT). Node/bun scripts with the same env work.
Expected
Honor NODE_OPTIONS DNS order, or document that compiled builds do not. Honor NO_PROXY for loopback even when ALL_PROXY is set.
Suggested fix
Compile with Bun env-proxy plus dns-result-order support, or document the limitation in CLI networking docs.
Summary
The compiled OpenCode binary (Bun) ignores NODE_OPTIONS=--dns-result-order=ipv4first. It also often ignores NO_PROXY when HTTP_PROXY/ALL_PROXY are set, so loopback HTTP backends get sent through CONNECT.
Repro
Actual
Compiled binary still uses AAAA (or sends loopback through CONNECT). Node/bun scripts with the same env work.
Expected
Honor NODE_OPTIONS DNS order, or document that compiled builds do not. Honor NO_PROXY for loopback even when ALL_PROXY is set.
Suggested fix
Compile with Bun env-proxy plus dns-result-order support, or document the limitation in CLI networking docs.