(I am trying to understand how ELB networking works within a VPC, and post this question)
When we add two subnets to a public ELB, aws elb create-load-balancer --load-balancer-name my-load-balancer --listeners "Protocol=HTTP,LoadBalancerPort=80,InstanceProtocol=HTTP,InstancePort=80" --subnets subnet-15aaab61 subnet-198aab81
, I assume I need to setup these two subnets as public subnets before running the this step -- is this understanding correct? Also, I assume the above public subnets must be configured to automatically assign public IPs to each of its instances (otherwise, DNS resolution of this ELB destination won't get a public addressable IP) -- is this understanding also correct?
Next, I have instances running in two private subnets and I register them to the ELB that were created above. I guess I need to make sure the two public subnets and the two private subnets are connected -- do I need to do extra work to make that happen? (i.e., Will the default 10.0.0.0/16 -> local rule be sufficient? I thought so, but [1] seems to say otherwise because it added a NAT rule in the context of ELB setup procedure)
Thanks for helping me understand the ELB related networking.