Code structure is mentioned in the file name code_structure.txt
Explanation -
Module approach is used to work on this assignment to package the resources into two different directories names ec2 and vpc present in modules directory and they are explained below -
ec2 - Security group for LoadBalancer and EC2, LoadBalancer with its listener and target group, Launch template with Autoscaling group.
vpc - VPC configuration with public and private subnets, InternetGateway and NATGateway with Route tables and its routes.
terraform.tfvars has all the configuration for the module variables.
terraform.tf has module block to call modules ec2 and vpc.
Use of count and for_each functions while creating multiple subnets or multiple ingress / egress security group rules.
Note -
In terraform.tfvars their is commented block of listeners from L76-L93 due to certificate_arn argument which is required for HTTPS listener, if given correct value for the arn then redirect HTTP_301 will work absolutely fine
Code structure is mentioned in the file name `code_structure.txt`
Explanation -
* Module approach is used to work on this assignment to package the resources into two different directories names `ec2` and `vpc` present in `modules` directory and they are explained below -
* `ec2` - Security group for LoadBalancer and EC2, LoadBalancer with its listener and target group, Launch template with Autoscaling group.
* `vpc` - VPC configuration with public and private subnets, InternetGateway and NATGateway with Route tables and its routes.
* `terraform.tfvars` has all the configuration for the module variables.
* `terraform.tf` has module block to call modules `ec2` and `vpc`.
* Use of `count` and `for_each` functions while creating multiple subnets or multiple ingress / egress security group rules.
* Note -
* In `terraform.tfvars` their is commented block of listeners from L76-L93 due to `certificate_arn` argument which is required for HTTPS listener, if given correct value for the arn then redirect HTTP_301 will work absolutely fine
Code structure is mentioned in the file name
code_structure.txt
Explanation -
Module approach is used to work on this assignment to package the resources into two different directories names
ec2
andvpc
present inmodules
directory and they are explained below -ec2
- Security group for LoadBalancer and EC2, LoadBalancer with its listener and target group, Launch template with Autoscaling group.vpc
- VPC configuration with public and private subnets, InternetGateway and NATGateway with Route tables and its routes.terraform.tfvars
has all the configuration for the module variables.terraform.tf
has module block to call modulesec2
andvpc
.Use of
count
andfor_each
functions while creating multiple subnets or multiple ingress / egress security group rules.Note -
terraform.tfvars
their is commented block of listeners from L76-L93 due tocertificate_arn
argument which is required for HTTPS listener, if given correct value for the arn then redirect HTTP_301 will work absolutely fine