Skip to content

Latest commit

 

History

History
43 lines (30 loc) · 1.83 KB

README.md

File metadata and controls

43 lines (30 loc) · 1.83 KB

AUTO SCALING AN APPLICATION WITH TERRAFORM ON AWS

Overview

This repository contains Terraform scripts to provision and manage infrastructure on AWS.

Description

The scripts in this repository automate the deployment of a scalable and highly available web application architecture on Amazon Web Services (AWS). The infrastructure includes:

  • Network Setup: Creates a Virtual Private Cloud (VPC), subnets in different availability zones, and associates them with a custom route table and an internet gateway for internet access.

  • Security Configuration: Establishes security groups controlling inbound and outbound traffic to EC2 instances.

  • Instance Configuration: Sets up launch configurations for EC2 instances running an Apache web server and generates an HTML page displaying instance metadata.

  • Auto Scaling and Load Balancing: Implements an Auto Scaling Group (ASG) and an Application Load Balancer (ALB) for distributing traffic among instances.

Prerequisites

Usage

  1. Clone this repository:

    git clone https://github.com/SESUGH-OPS/AWS-TERRAFORM-AUTSCALING.git
    cd AWS-Terraform-Infrastructure/
  2. Initialize Terraform and apply the configuration:

    terraform init
    terraform apply

Cleanup

To avoid incurring charges, ensure to destroy the resources after use:

terraform destroy

You get output such as this

Screenshot from 2023-11-19 14-59-11