how to set same IP for multiple instances when using outgoing restful request?

0

Hi, I am trying to use 3rd party services with my EC2 instances. The 3rd party service has some security rules. one of them is that my instance's IP has to be whitelisted.

I am working with multiple instances that can be scaled over time and I don't want to set Elastic IP for each instance. and I don't want to register new IP every time I'm adding a new instance.

Is there a way to use a service (maybe proxy) that listen to all my instances and forward the outgoing request with the same IP?

I also believe it is more secure to put my outgoing requests behind a proxy.

Can I get an explanation/tutorial for doing that?

Thank you! Asaf

已提問 1 年前檢視次數 200 次
1 個回答
1

This is presented as a use case for a NAT Gateway.

When you create a public NAT Gateway you associate it with an elastic IP which the IP address that outside services would see when it is used by your servers:

The NAT gateway replaces the source IP address of the instances with the IP address of the NAT gateway. For a public NAT gateway, this is the elastic IP address of the NAT gateway.

已回答 1 年前
專家
已審閱 1 年前
  • Exactly, assuming the EC2 instances don't need to be public and accepting inbound requestd from the internet - a reasonable assumption given it's a scaled fleet.

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

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

回答問題指南