Skip to content
This repository was archived by the owner on Dec 10, 2021. It is now read-only.

Outbound traffic is not being routed via gw (multi-zone configuration) #88

@huang-jy

Description

@huang-jy

I have a regional GKE cluster and want to have a NAT box in each zone and all traffic within the zone routed via the corresponding nat, to hide the IP of the worker nodes.

I have attempted to use this example as a starting point:

https://github.com/GoogleCloudPlatform/terraform-google-nat-gateway/blob/master/examples/ha-nat-gateway/main.tf

The config creates the nat boxes, but when I run a pod using alpine and curl ipinfo.io/ip from within the container to get the external ip as seen by the container in the cluster, it returns the ip of the host, meaning the routing to send outbound traffic from the cluster to the nat gw isn't there.

Am I missing something? Or is the example incomplete?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions