Terraform module for ec2-instance on aws
module "ec2-instance" {
source = "registry.patterneddesigns.ca/patterneddesigns/ec2-instance/aws"
version = "0.1.0"
}instance_name
requiredName tag for the EC2 instance. Appears in the AWS Console for identification.
ami_id
requiredAMI ID for the instance. AMI IDs are region-specific. Use data sources instead of hardcoded AMI IDs.
subnet_id
requiredSubnet ID for the instance. Use private subnets for backend services, public subnets for internet-facing instances.
instance_typeEC2 instance type. Common types: t3.micro (dev), t3.small (small apps), t3.medium (general purpose), m5.large (production).
instance_idID of the EC2 instance. Use this for resource references.
public_ipPublic IP address of the instance (if applicable).
private_ipPrivate IP address of the instance.