Skip to content

Commit a8346f6

Browse files
committed
Add aarch64 ASG capacity provider
1 parent 2884081 commit a8346f6

File tree

1 file changed

+39
-39
lines changed

1 file changed

+39
-39
lines changed

spire/templates/shared-ecs/asg-aarch64.yml

Lines changed: 39 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ Parameters:
4141

4242
Conditions:
4343
IsProduction: !Equals [!Ref EnvironmentType, Production]
44-
# IsStaging: !Equals [!Ref EnvironmentType, Staging]
44+
IsStaging: !Equals [!Ref EnvironmentType, Staging]
4545
IsPrimaryRegion: !Equals [!Ref RegionMode, Primary]
4646
KeepAsgAlive: !And [!Condition IsProduction, !Condition IsPrimaryRegion]
4747
EnableNestedChangeSetScrubbingResources: !Equals [!Ref NestedChangeSetScrubbingResourcesState, Enabled]
@@ -400,44 +400,44 @@ Resources:
400400
- !Ref VpcPublicSubnet2Id
401401
- !Ref VpcPublicSubnet3Id
402402

403-
# DefaultCapacityProvider:
404-
# Type: AWS::ECS::CapacityProvider
405-
# Properties:
406-
# AutoScalingGroupProvider:
407-
# AutoScalingGroupArn: !Ref Asg
408-
# ManagedDraining: ENABLED
409-
# ManagedScaling:
410-
# InstanceWarmupPeriod: 180
411-
# MaximumScalingStepSize: 10
412-
# MinimumScalingStepSize: 1
413-
# Status: ENABLED
414-
# TargetCapacity: !If
415-
# - IsProduction
416-
# - 100
417-
# - 100
418-
# ManagedTerminationProtection: DISABLED
419-
# Tags:
420-
# - { Key: prx:meta:tagging-version, Value: "2021-04-07" }
421-
# - { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
422-
# - { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
423-
# - { Key: prx:cloudformation:root-stack-name, Value: !Ref RootStackName }
424-
# - { Key: prx:cloudformation:root-stack-id, Value: !Ref RootStackId }
425-
# - { Key: prx:ops:environment, Value: !Ref EnvironmentType }
426-
# - { Key: prx:dev:application, Value: Common }
427-
# ClusterCapacityProviderAssociation:
428-
# Type: AWS::ECS::ClusterCapacityProviderAssociations
429-
# Properties:
430-
# Cluster: !Ref EcsClusterName
431-
# CapacityProviders:
432-
# - !Ref DefaultCapacityProvider
433-
# - !If [IsStaging, FARGATE, !Ref "AWS::NoValue"]
434-
# - !If [IsStaging, FARGATE_SPOT, !Ref "AWS::NoValue"]
435-
# DefaultCapacityProviderStrategy:
436-
# # With only one default capacity provider, the base and weight won't
437-
# # factor into scheduling; everything will be even within the ASG
438-
# - Base: 0
439-
# Weight: 1
440-
# CapacityProvider: !Ref DefaultCapacityProvider
403+
DefaultCapacityProvider:
404+
Type: AWS::ECS::CapacityProvider
405+
Properties:
406+
AutoScalingGroupProvider:
407+
AutoScalingGroupArn: !Ref Asg
408+
ManagedDraining: ENABLED
409+
ManagedScaling:
410+
InstanceWarmupPeriod: 180
411+
MaximumScalingStepSize: 10
412+
MinimumScalingStepSize: 1
413+
Status: ENABLED
414+
TargetCapacity: !If
415+
- IsProduction
416+
- 100
417+
- 100
418+
ManagedTerminationProtection: DISABLED
419+
Tags:
420+
- { Key: prx:meta:tagging-version, Value: "2021-04-07" }
421+
- { Key: prx:cloudformation:stack-name, Value: !Ref AWS::StackName }
422+
- { Key: prx:cloudformation:stack-id, Value: !Ref AWS::StackId }
423+
- { Key: prx:cloudformation:root-stack-name, Value: !Ref RootStackName }
424+
- { Key: prx:cloudformation:root-stack-id, Value: !Ref RootStackId }
425+
- { Key: prx:ops:environment, Value: !Ref EnvironmentType }
426+
- { Key: prx:dev:application, Value: Common }
427+
ClusterCapacityProviderAssociation:
428+
Type: AWS::ECS::ClusterCapacityProviderAssociations
429+
Properties:
430+
Cluster: !Ref EcsClusterName
431+
CapacityProviders:
432+
- !Ref DefaultCapacityProvider
433+
- !If [IsStaging, FARGATE, !Ref "AWS::NoValue"]
434+
- !If [IsStaging, FARGATE_SPOT, !Ref "AWS::NoValue"]
435+
DefaultCapacityProviderStrategy:
436+
# With only one default capacity provider, the base and weight won't
437+
# factor into scheduling; everything will be even within the ASG
438+
- Base: 0
439+
Weight: 1
440+
CapacityProvider: !Ref DefaultCapacityProvider
441441

442442
Outputs:
443443
AsgName:

0 commit comments

Comments
 (0)