docs: resolve HaRP per request and pass WebSockets in the nginx examples - #121
Conversation
With a container name in proxy_pass, nginx refuses to start whenever that container is absent and the whole server block goes down; a variable plus a resolver avoids it. Signed-off-by: Oleksandr Piskun <oleksandr2088@icloud.com>
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (1)
Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe README NGINX example now sets HTTP/1.1 and the Priority: ⬇️ Low Merge Risk: ⚪ Minimal · up to The README now documents WebSocket forwarding and a resolver-based alternative for container DNS names. The examples preserve the server settings and explain when to use each, with no identified blocker to merging. Architecture SummaryArchitecture risk: 🔵 Low · up to The change affects 1 system. Changed systems: Architecture concerns Review detailsSystems and components
Before / after behavior
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Advanced
Run ID: f76bae30-e45b-4d8a-b760-f99cf50efc25
📒 Files selected for processing (1)
README.md
Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review.
| Put the upstream in a variable, which nginx resolves per request, and give it a resolver: | ||
|
|
||
| ```nginx | ||
| resolver 127.0.0.11 valid=30s; # Docker's embedded DNS; use your own resolver outside Docker |
There was a problem hiding this comment.
maybe this is not required to be set?
Signed-off-by: Oleksandr Piskun <oleksandr2088@icloud.com>
Signed-off-by: Oleksandr Piskun <oleksandr2088@icloud.com>
The nginx example uses an IP, so it never hits this: with a container name in
proxy_pass, nginx resolves it once at startup and refuses to start whenever the HaRP container is absent (host not found in upstream), taking every vhost of that server down. Verified on nextcloud-docker-dev, where the proxy is nginx-proxy and HaRP isappapi-harp. The new example puts the upstream in a variable with a resolver, which degrades to a 502 on/exapps/instead, and says when Docker's127.0.0.11resolver applies. Requested in nextcloud/nextcloud-skills#9.Both nginx examples also dropped WebSockets: without
proxy_http_version 1.1and theUpgrade/Connectionheaders nginx never forwards the upgrade, so ExApp WebSockets did not reach HaRP even though HaRP supports them.