| name | deploy-ec2-aws |
| description | Deploy and manage AWS EC2 nodes using Terraform. |
Deploy EC2 AWS
Overview
Scaffold a self-contained Terraform project, then provision one or more named EC2 node groups on AWS. Create a dedicated VPC and public subnet, allow private communication among nodes, restrict SSH ingress, and assign a stable Elastic IP to every node.
Before running live AWS or Terraform commands, read references/deployment.md.
Inputs And Defaults
Require every node group to have a unique name and positive count. Ask for either value if missing.
Accept CPU and memory as optional minimum requirements. When omitted, use the small default:
- CPU:
2 vCPU
- Memory:
4 GiB
- Resolved type:
t3.medium
Use repeated node specifications for differently named groups:
api=2
worker=3:4:8
The format is NAME=COUNT[:CPU:MEMORY_GIB]. CPU and memory are minimums; the resolver may select a slightly larger x86_64 instance type when AWS has no exact match. Do not silently change an explicit count.
Use the node group name as the EC2 Name tag. For a group with one node, use the exact group name. For a group with multiple nodes, append zero-padded sequence numbers such as api-01 and api-02. Do not prefix EC2 names with the deployment namespace.
Defaults:
- Namespace:
ec2-nodes-<YYMMDDHHMM> using local time
- Project path:
$HOME/test/ec2-aws-<namespace>
- AWS profile:
default
- Region:
us-west-2
- Root volume:
20 GiB encrypted GP3