I'm having a frustrating issue with my service that's exposed through the Gateway API using Envoy Gateway. Initially, everything works perfectly, but then it starts returning this error: 'upstream connect error or disconnect/reset before headers. reset reason: connection timeout'. I've tested the service with curl from within the Kubernetes cluster, and it responds correctly. However, when I try to access it via a web browser, I get that timeout error. It's only happening with this specific service, while others in the cluster are functioning properly. This service is also the only one operating on the apex domain. I've attached my Gateway and HTTPRoute YAML configurations for your reference. Any insights on why this might be happening would be greatly appreciated!
1 Answer
It sounds like your issue is related to the Envoy Gateway having trouble maintaining connections. Since the service works internally what's likely happening is Envoy is facing a timeout when trying to access the service from outside. Check the Envoy logs; they’ll give you more details on whether the service is listening or if the proxy is unable to reach it.

I checked Envoy's logs, and I only see this when it happens: the response code is 503, which means it reset the connection before it could respond. All other logs seem fine, and nothing seems to be happening on the app pod.