This template creates an Auto Scaling group with a launch template and a lifecycle hook. The launch template is used to configure the instances in the Auto Scaling group, including the image, instance type, security groups, and user data. The lifecycle hook is used to perform a custom action on instances when they are launched. In this example, the lifecycle hook keeps each instance in a wait state for 60 seconds to allow the user data script to complete before the instance enters the InService state.

myAppLaunchTemplate
AWS::EC2::LaunchTemplate


LaunchTemplateData *
BlockDeviceMappings
CapacityReservationSpecification
CapacityReservationTarget
CpuOptions
CreditSpecification
ElasticGpuSpecifications
ElasticInferenceAccelerators
EnclaveOptions
HibernationOptions
IamInstanceProfile
InstanceMarketOptions
SpotOptions
InstanceRequirements
AcceleratorCount

AcceleratorManufacturers

AcceleratorNames

AcceleratorTotalMemoryMiB

AcceleratorTypes

AllowedInstanceTypes

BaselineEbsBandwidthMbps

CpuManufacturers

ExcludedInstanceTypes

InstanceGenerations

LocalStorageTypes

MemoryGiBPerVCpu
MemoryMiB *
NetworkBandwidthGbps
NetworkInterfaceCount
TotalLocalStorageGB
VCpuCount *
LicenseSpecifications
MaintenanceOptions
MetadataOptions
Monitoring
NetworkInterfaces
Placement
PrivateDnsNameOptions

SecurityGroupIds

SecurityGroups

TagSpecifications

myASG
AWS::AutoScaling::AutoScalingGroup


LaunchTemplate
LifecycleHookSpecificationList

VPCZoneIdentifier

CloudFormation Template

Share Template