From the course: Learning Terraform
Unlock this course with a free trial
Join today to access over 25,500 courses taught by industry experts.
Expanding your installation - Terraform Tutorial
From the course: Learning Terraform
Expanding your installation
In this lesson, we'll be setting up a load balancer and an auto-scaling group for our application. First, we'll set up the load balancer and just point it to our single instance. We'll go to the Terraform registry and search for ALB. We're looking for this module here, terraform-aws-modules-slash-ALB. If you scroll down, there's an example here. This is a little bit more complex than what we need, but we can adapt it to our use. It's just the HTTP to HTTPS redirect. Just click copy and go back to your code and open up main.tf. Let's put this right below our rephrase. Let's put this just at the end of our code after our security group. So, we'll scroll up to the top, and the first thing we'll do is we'll rename this to blog underscore ALB, just to match the pattern we've been using. And we can do the same thing for the name parameter. This is the one that will actually show up in AWS, so choose something…