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

First request always returns 502 Bad Gateway #21

Open
robosoul opened this issue Mar 26, 2017 · 1 comment
Open

First request always returns 502 Bad Gateway #21

robosoul opened this issue Mar 26, 2017 · 1 comment

Comments

@robosoul
Copy link

I noticed a pattern:

  1. start container
$ docker run -d -p 5566:5566 -p 4444:4444 --env tors=25 mattes/rotating-proxy
a82c7efd44798f5d0686e372663a3302a2df429b810e8302a2c69435efb57e07
  1. send request
$ curl --proxy localhost:5566 http://www.example.com -I
HTTP/1.0 502 Bad Gateway
Cache-Control: no-cache
Connection: close
Content-Type: text/html
  1. send request after the first one returned 502:
$ curl --proxy localhost:5566 http://www.example.com -I
HTTP/1.1 200 OK
Content-Length: 606
ETag: "359670651"
Date: Sun, 26 Mar 2017 08:56:23 GMT
Last-Modified: Fri, 09 Aug 2013 23:54:35 GMT
Expires: Sun, 02 Apr 2017 08:56:23 GMT
Content-Encoding: gzip
Accept-Ranges: bytes
Content-Type: text/html
Server: ECS (iad/182A)
X-Cache: HIT
Age: 1
Connection: keep-alive

Any idea why's the first time response 502 ?

Tnx,
Luka

@ilcn
Copy link

ilcn commented Aug 18, 2017

For me waiting for around 5 min works -- it initially returned all 504, but after 5 mins its started working. Maybe it needs a bit "warm up" time?

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

No branches or pull requests

2 participants