Let's say I have VPC, Demo_VPC with subnet 10.0.0.0/16
; I also create two subnets each providing public and private access. But public subnet is straightforward to communicate with internet, whereas private I like to use NAT instance. As it is defined in aws documentation NAT instance will serve the purpose to keep private subnet hidden from internet still use internet via NAT instance.
I am stuck to understand the point. If the webserver is in a public subnet, the NAT instance is also in a public subnet in the same availability zone. Other instances are in a private subnet but they are in different availability zones. How will I make this private subnet to direct traffic toward NAT instance in different availability zone but are in same VPC?
I am new to aws trying to understand networking part of it.