Third party apis not accessible through beanstalk application.

0

I have a nodejs rest application hosted on elastic beanstalk with load balancer enabled. The application makes external apis calls but not of them are working. One example call is https://www.googleapis.com/oauth2/v3/userinfo?access_token=${accessToken} . I have enabled all inbound/outbound rules to allow traffic from 0/0.0.0.0 on the load balancer security groups, vpc, subnets, but it still doesn't work. I have an internet gateway also attached to the vpc. The subnet has route table with internet gateway.

1 個回答
0

Hello.

Does EC2 have a public IP address?
If a public IP address is not assigned, you will not be able to communicate with the public API even if you launch EC2 in a subnet that has a route to the Internet gateway.
If EC2 does not have a public IP address, why not try using NAT Gateway?
https://docs.aws.amazon.com/vpc/latest/userguide/vpc-nat-gateway.html

profile picture
專家
已回答 1 個月前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南