I’m trying to deploy an app, and when trying to access it, the browser keep loading for a while and in the logs I just saw this message:
Could not proxy HTTP request. Retrying in 20 ms (attempt 1)
Could not proxy HTTP request. Retrying in 1000 ms (attempt 10)
Could not proxy HTTP request. Retrying in 1000 ms (attempt 20)
Could not proxy HTTP request. Retrying in 1000 ms (attempt 30)
Could not proxy HTTP request. Retrying in 972 ms (attempt 40)
Could not proxy HTTP request. Retrying in 1000 ms (attempt 50)
Could not proxy HTTP request. Retrying in 1000 ms (attempt 60)
Any idea what could be? Where I can get more info?
I was trying to access my web app on my browser on my computer because it has a URL. I couldn’t access it, check the monitoring and saw I was getting the same error as you. But I checked on another device and it was working fine. So, I restarted my computer and the error is gone.
I was facing the same issue this morning, but only on one instance of my application.
Restarting does seem to work.
I restarted postgres, but that might be unnecessary.
I restarted the application itself with: flyctl apps restart APP_NAME
Try incognito or a different browser. I think there is some caching at play here.
I just had the same problem and using incognito on Chrome worked
Logs are now:
Could not proxy HTTP request. Retrying in 1000 ms (attempt 20)
Could not proxy HTTP request. Retrying in 1000 ms (attempt 30)
2023-02-03T03:56:49.958 app[56334732] yyz [info] 03:56:49.957 request_id=F0A0VxJp4Mhu6NUAAAER [info] GET /
2023-02-03T03:56:49.958 app[56334732] yyz [info] 03:56:49.958 request_id=F0A0VxJp4Mhu6NUAAAER [info] Sent 200 in 576µs
2023-02-03T03:56:50.557 app[56334732] yyz [info] 03:56:50.556 request_id=F0A0VzYfNqIx-S4AAAEh [info] GET /
2023-02-03T03:56:50.557 app[56334732] yyz [info] 03:56:50.557 request_id=F0A0VzYfNqIx-S4AAAEh [info] Sent 200 in 548µs
This error means our proxy can’t get an HTTP response from your app.
The best way to troubleshoot this is to run fly ssh console, and then test your app with curl. If your app is listening on port 8080, you can test with curl like this:
curl http://0.0.0.0:8080 -v
If you’re running multiple instances, you may need to ssh to the one you see erroring in the logs. fly ssh console -s will let you pick a specific VM.