📦 Overview
The Terraform AWS Resource Master is a “main” module that ties together multiple submodules to provision
a complete
AWS environment. Out of the box it can create:
- VPC with public/private subnets, NAT gateways, route tables
- EC2 instances with customizable AMIs, instance types, security groups
- RDS instances (MySQL/Postgres) with configurable storage & backups
- S3 buckets for app storage and logging
- Plus optional submodules for CloudWatch alarms, DynamoDB tables, Lambda functions, and more
⚙️ Prerequisites
- AWS account with IAM permissions for networking, compute, storage, database
- Terraform v1.0+ installed locally
- AWS CLI configured (
aws configure
) or environment variables set
🚀 Quick Start
Create a root main.tf
and reference the module:
module "resource_master" {
source = "Pradipbabar/resource-master/aws/"
enable_vpc = true
enable_ec2 = true
enable_rds = true
enable_s3 = true
# enable_cloudwatch = true
# enable_dynamodb = true
}
Then run:
terraform init
terraform apply
To tear down:
terraform destroy
đź”— Submodules
- VPC: Public/private subnets, NAT, route tables
- EC2: Auto-scaled or fixed EC2 fleets
- RDS: MySQL/Postgres with backups & multi-AZ
- S3: Primary buckets + logging buckets
- CloudWatch: Alarms on CPU, disk, network
- DynamoDB: On-demand or provisioned tables
- …and more via additional modules (Lambda, IAM roles, etc.)
📤 Outputs
Each submodule exports useful values for chaining or reference:
- VPC ID, subnet IDs, route table IDs
- EC2 instance IDs, public IPs
- RDS endpoint, port
- S3 bucket ARNs
- CloudWatch alarm ARNs
Check each submodule’s README for the full list.
đź”® Future Enhancements
- Support for private DNS zones & Transit Gateway
- Built-in Bastion Host & Session Manager setup
- Terraform Cloud & state backends examples
- Automated “blue/green” RDS upgrades