https://github.com/sandyn12058/terraform-project
This Terraform project demonstrates an end-to-end VPC setup on AWS, leveraging Infrastructure-as-Code (IaC). It automates network architecture with path-based routing via an internet-facing load balancer and scales instances using Auto Scaling Groups, ensuring repeatable and consistent deployments.
https://github.com/sandyn12058/terraform-project
aws aws-cli cloud-automation infrastructure-as-code shell-scripting terraform
Last synced: about 2 months ago
JSON representation
This Terraform project demonstrates an end-to-end VPC setup on AWS, leveraging Infrastructure-as-Code (IaC). It automates network architecture with path-based routing via an internet-facing load balancer and scales instances using Auto Scaling Groups, ensuring repeatable and consistent deployments.
- Host: GitHub
- URL: https://github.com/sandyn12058/terraform-project
- Owner: SandyN12058
- Created: 2025-04-06T12:42:16.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2025-04-09T17:12:36.000Z (about 1 year ago)
- Last Synced: 2025-04-10T02:41:52.361Z (about 1 year ago)
- Topics: aws, aws-cli, cloud-automation, infrastructure-as-code, shell-scripting, terraform
- Language: HCL
- Homepage:
- Size: 180 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# 🚀 AWS Scalable Web App Deployment using Terraform
Originally configured via AWS Console for learning, later refactored into Terraform for version control and better visibility.
This project provisions a highly available and scalable infrastructure on AWS using Terraform. It includes:
- An **Application Load Balancer (ALB)** for routing HTTP traffic
- Two **Auto Scaling Groups (ASGs)** for different applications
- Two **Target Groups (TGs)** with path-based routing
- **Launch Templates (LTs)** for EC2 instance configuration
---
## 🧰 Prerequisites
- ✅ [Terraform](https://www.terraform.io/downloads)
- ✅ [AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/install-cliv2.html)
- ✅ AWS account with programmatic access (Access Key & Secret Key)
- ✅ EC2 AMI configured with an app running on:
- Port `8000` for `/app1`
- Port `8001` for `/app2`
---
## ⚙️ How to Deploy
#### 1. Clone the repository
```bash
git clone https://github.com/SandyN12058/Terraform-project.git
cd terraform-project
```
#### 2. Initialize Terraform
```bash
terraform init
```
#### 3. Preview the execution plan
```bash
terraform plan
```
#### 4. Apply the configuration
```bash
terraform apply
```
#### 5. Destroy the configuration
```bash
terraform destroy
```
---
## 🌐 Application Access
Once deployed, access your application at:
`http:///app1/` → App running on port 8000
`http:///app2/` → App running on port 8001