Load Balancing

Now it's time to use the AMI to launch some instances and load balance.

Launching Instances

step 1:

Go an launch a new instance for the qr code app

Go an launch a new instance for the qr code app
step 2:

In the AMI section, select My AMIs, Owned by me and make sure the qr app AMI is selected

In the AMI section, select **My AMIs**, **Owned by me** and make sure the qr app AMI is selected
step 3:

Since we'll never login or modify this instance, proceed without a key pair

Since we'll never login or modify this instance, proceed without a key pair
step 4:

In the network settings, click Edit

In the network settings, click **Edit**
step 5:

Disable public IP assignment

We will never access these instances over the public internet

**Disable** public IP assignment    We will never access these instances over the public internet
step 6:

Select Custom TCP and Port range 3000

This is the port for the internal HTTP server

Select **Custom TCP** and **Port range** 3000    This is the port for the internal HTTP server
step 7:

Select Custom for the Source type and enter the cidr block for the VPC.

Select **Custom** for the **Source type** and enter the cidr block for the VPC.

This instance will only allow access on port 3000 from within the VPC's private network. We generally want to keep most of the infrastructure as private as possible, and only expose what's necessary.

In this case, we'll expose a load balancer to the public internet, while keeping everything else private.

Cloud Course
Cloud Course
$89.70
$299.00 Lifetime
  • 81+ learning resources
  • 57 lessons and tutorials
  • 15 hands-on deployments
  • 9 quizzes
  • 29 videos (4h 17m 38s)
  • More content coming soon
  • Unlimited lifetime access to all course content
  • Deployment assessment CLI tool
  • Exclusive Discord access
Original Price:$299.00
Discount:-$209.30
Total:$89.70