Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save sk-t3ch/a3fb121f19753647df4f3f0e25f4fcff to your computer and use it in GitHub Desktop.
Save sk-t3ch/a3fb121f19753647df4f3f0e25f4fcff to your computer and use it in GitHub Desktop.
Hello World Cluster CloudFormation - Auto Scaling Group Using Spot Fleet
AutoScalingGroup:
Type: AWS::AutoScaling::AutoScalingGroup
Properties:
MinSize: "1"
MaxSize: "2"
DesiredCapacity: "2"
HealthCheckGracePeriod: 300
MixedInstancesPolicy:
InstancesDistribution:
OnDemandBaseCapacity: 1
OnDemandPercentageAboveBaseCapacity: 0
SpotAllocationStrategy: capacity-optimized
LaunchTemplate:
LaunchTemplateSpecification:
LaunchTemplateId: !Ref LaunchTemplate
Version: !GetAtt LaunchTemplate.LatestVersionNumber
Overrides:
- InstanceType: t3.micro
- InstanceType: t3a.micro
- InstanceType: t2.micro
VPCZoneIdentifier:
- !ImportValue PrivateSubnetA
- !ImportValue PrivateSubnetB
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment