Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add OnDemandBaseCapacity parameter #1364

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions templates/aws-stack.yml
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ Metadata:
Parameters:
- MinSize
- MaxSize
- OnDemandBaseCapacity
- OnDemandPercentage
- SpotAllocationStrategy
- ScaleOutFactor
Expand Down Expand Up @@ -324,6 +325,12 @@ Parameters:
Type: String
Default: "10s"

OnDemandBaseCapacity:
Description: Specify how much On-Demand capacity the Auto Scaling group should have for its base portion before scaling by percentages. The maximum group size will be increased (but not decreased) to this value.
Type: Number
Default: ""
MinValue: 0

OnDemandPercentage:
Description: Percentage of total instances that should launch as OnDemand. Default is 100% OnDemand - reduce this to use some Spot Instances when they're available and cheaper than the OnDemand price. A value of 70 means 70% OnDemand and 30% Spot Instances.
Type: Number
Expand Down Expand Up @@ -1321,6 +1328,7 @@ Resources:
VPCZoneIdentifier: !If [ "CreateVpcResources", [ !Ref Subnet0, !Ref Subnet1 ], !Ref Subnets ]
MixedInstancesPolicy:
InstancesDistribution:
OnDemandBaseCapacity: !Ref OnDemandBaseCapacity
OnDemandPercentageAboveBaseCapacity: !Ref OnDemandPercentage
SpotAllocationStrategy: !Ref SpotAllocationStrategy
LaunchTemplate:
Expand Down