Static IP on Application Load Balancer

(By putting it behind a Network Load Balancer)


This site, https://network.exampleloadbalancer.com/ is served by an Application Load Balancer, behind a Network Load Balancer. Clients connect to one of the static IP addresses of the Network Load Balancer, and are forwarded to one of the non-static IPs of the Application Load Balancer.

So clients will always see the same, static, IP addresses of the Network Load Balancer, in this case, querying DNS will show:


ec2-user@ip-10-3-4-5~> host network.exampleloadbalancer.com
network.exampleloadbalancer.com is an alias for network-exampleloadbalancer-com-3784b7065f992f3c.elb.us-east-1.amazonaws.com.
network-exampleloadbalancer-com-3784b7065f992f3c.elb.us-east-1.amazonaws.com has address 54.156.231.230
network-exampleloadbalancer-com-3784b7065f992f3c.elb.us-east-1.amazonaws.com has address 34.237.219.191
                    

Instead of the changing IPs of the Application Load Balancer, like:


ec2-user@ip-10-3-4-5~> date
Fri Apr 13 11:31:09 DST 2018
ec2-user@ip-10-3-4-5~> host internal-exampleloadbalancer-inside-1234567890.us-east-1.elb.amazonaws.com
internal-exampleloadbalancer-inside-1234567890.us-east-1.elb.amazonaws.com has address 192.168.101.191
internal-exampleloadbalancer-inside-1234567890.us-east-1.elb.amazonaws.com has address 192.168.102.39
internal-exampleloadbalancer-inside-1234567890.us-east-1.elb.amazonaws.com has address 192.168.103.214
internal-exampleloadbalancer-inside-1234567890.us-east-1.elb.amazonaws.com has address 192.168.104.42

ec2-user@ip-10-3-4-5~> date
Fri Apr 20 14:23:59 DST 2018
ec2-user@ip-10-3-4-5~> host internal-exampleloadbalancer-inside-1234567890.us-east-1.elb.amazonaws.com
internal-exampleloadbalancer-inside-1234567890.us-east-1.elb.amazonaws.com has address 192.168.101.168
internal-exampleloadbalancer-inside-1234567890.us-east-1.elb.amazonaws.com has address 192.168.102.139
internal-exampleloadbalancer-inside-1234567890.us-east-1.elb.amazonaws.com has address 192.168.103.14
internal-exampleloadbalancer-inside-1234567890.us-east-1.elb.amazonaws.com has address 192.168.104.109