Status Update
Comments
ha...@google.com <ha...@google.com>
ge...@google.com <ge...@google.com> #2
To solve this problem, create the two routes with different priorities, like this:
Route1: Destination:0.0.0.0/0<-------> Next hop: ILB(IN us-east1) <------> Priority:950
Route2: Destination:0.0.0.0/0<-------> Next Hop: ILB(IN us-west1) <------> Priority:951
As long as the forwarding rules aren't configured to be
From the perspective of us-west1, this route is available:
Route2: Destination:0.0.0.0/0<-------> Next Hop: ILB(IN us-west1) <------> Priority:951
From the perspective of us-east1, this one is available:
Route1: Destination:0.0.0.0/0<-------> Next hop: ILB(IN us-east1) <------> Priority:950
It doesn't matter that these have different priorities in the route table because only one is "active" in each region (as long as global access isn't configured).
Description
What you would like to accomplish:
Select subnet route exchange on VPC peering and not peer all subnets.
How this might work:
When we create a VPC peering have the option to select the subnets that we want to peer.
If applicable, reasons why alternative solutions are not sufficient:
Alternative solution is to use a NAT instance, but this can be a performance issue.
Other information (workarounds you have tried, documentation consulted, etc):
This will help on managing IPs for GKE cluster, since with this we can have a isolated VPC for GKE clusters and then do a vpc peering with a shared vpc where only we route exchange the node ip subnet.