AWS App Runner timing out on outbound HTTPS requests

0

I have an AppRunner service connected to a VPC: AppRunner Network Configuration

In my VPC, I attached the Internet Gateway also the NAT Gateway in each subnet. You can see here the resource map: Network Resource map.

My AppRunner instance is under a security group that have this outbound rules: AppRunner security group rules

I ran the Reachability Analyzer, selecting each network interface from my AppRunner instance and trying to reach the 8.8.8.8 ip. Here is an exemple of the result I have:

Reachability analyzer

In my AppRunner instance, the application have to access to internet resources. However it fails in timeout requesting those resources ex:

Unhandled exception. System.Net.Http.HttpRequestException: Connection timed out (xxx-bucket.s3.eu-west-1.amazonaws.com:443)

Can anyone help me to find what I'm missing here?

Regards,

profile picture
asked a year ago584 views
1 Answer
0
Accepted Answer

I finally found my problem.

Regarding the result of the reachability analyzer, we can see that the final destination is on the NAT gateway. The destination must be the Internet Gateway of the public network.

I had configured a single routing table for my environment and applied it to both the private and public networks which caused this error.

The solution should be as follows.

**Routing table of the public network **

DestinationTarget
<VPC Local CIDR>local
0.0.0.0/0internet-gateway-id

Routing table of the private network

DestinationTarget
<VPC Local CIDR>local
0.0.0.0/0nat-gateway-id

In the end, the reachability analyzer should indicate the destination as the Internet Gateway:

Final Reachability analyzer result

Regards,

profile picture
answered a year ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions