Problem with outgoing traffic in Google Cloud Job with NAT and static IP

  Kiến thức lập trình

I have written a service that requires a static IP for communication with an API. I followed Google’s instructions here https://cloud.google.com/run/docs/configuring/static-outbound-ip, and indeed, the traffic is now routed from a fixed IP.

The problem is that I observe random connection timeouts each time, especially with the first requests to the external API. To make sure that the issue is not related to a network problem or an issue with the external API.

I reproduced the problem with a very small Docker image that makes only a GET request to a requestbin once per second. I still experienced the same behavior. When I remove the NAT and the requests come from random IPs, everything works fine.

I cannot find what is wrong and why it doesn’t work correctly with NAT and static IP.

I want to route all outgoing traffic through a static IP.

Theme wordpress giá rẻ Theme wordpress giá rẻ Thiết kế website

LEAVE A COMMENT