The question is the same as this one but has screenshots of AWS resources' configurations.
Situation:
- A backend is hosted as an App Runner service.
- The backend needs to communicate with a private RDS instance. So, the App Runner service is add to a VPC.
- Backend can now communicate with the RDS instance.
Expected:
- Backend should also be able to make HTTP requests to the Internet.
Actual:
- Any HTTP request from the backend to the Internet takes forever/times out.
Checklist:
- An Internet gateway is connected.
- Route table is set to route 0.0.0.0/0 to the Internet gateway.
- Security group allows outbound access.
I've tried also putting a NAT gateway in place of the Internet gateway and set up the route table accordingly. But the behaviour was the same. Screenshots below are without the NAT gateway configuration.
Screenshots:
VPC Connector configuration on App Runner service
Security group outbound rule allowing all traffic
Route table routing outbound traffic to internet gateway
Route table association with all subnets (non-explicit. Default, didn't change)
How I know that my service has no outbound Internet access:
- I'm making a request google.com
- I've made a log before, after, and in catch of the request.
- Log happens before, but then nothing happens. And my API that invokes this request keeps loading forever (until it Gateway Timeouts after 5 minutes).
So, what is wrong in my configuration above/How can I give outbound Internet access to the service?
And btw, I can access the service itself (i.e., inbound traffic) through the domain generated by App Runner.
A related discussion: https://github.com/aws/apprunner-roadmap/issues/109