nginx-proxy: Occasional Error 502 Bad Gateway
We are currently running
Host: OS X 10.11.5 Docker Version 1.12.0-rc4-beta20 (build: 10404) Latest nginx-proxy (as of posting this the build from 2016-07-19)
On requesting the proxy, every now and then without recognizable pattern, we get a “502: Bad Gateway” producing the follow error in the log:
2016/07/27 16:36:11 [error] 56#56: *1910 upstream prematurely closed connection while reading response header from upstream, client: 172.19.0.1, server: ~^ourhost\.com\..*\.xip\.io, request: "GET /app_dev.php/de/test.html HTTP/1.1", upstream: "http://172.19.0.3:80/app_dev.php/de/test.html", host: "ourhost.com.127.0.0.1.xip.io", referrer: "http://ourhost.com.127.0.0.1.xip.io/app_dev.php/de/test-2.html"
We use the nginx-proxy in front of containers running Apache. Repeating the request in the browser usually fixes the 502.
Did some of you already experience this behavior? Where could we start to debug?
About this issue
- Original URL
- State: open
- Created 8 years ago
- Reactions: 7
- Comments: 21
Commits related to this issue
- strange SSL behavior, https://github.com/jwilder/nginx-proxy/issues/516 — committed to dina-web-nrm/media-docker by Inkimar 8 years ago
This could be a problem with docker 1.12.0. See https://github.com/docker/docker/issues/25698 and https://github.com/docker/docker/issues/24789.