-
Notifications
You must be signed in to change notification settings - Fork 4k
Commit
Support the new ECS::TaskDefinition ContainerDefinition VersionConsistency property. This is a simple enabled/disabled flag. Additionally, set a default disabled value if the container image is a CDK asset, for the reasons described in the comments.
- Loading branch information
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
{ | ||
"Resources": { | ||
"TaskDefTaskRole1EDB4A67": { | ||
"Type": "AWS::IAM::Role", | ||
"Properties": { | ||
"AssumeRolePolicyDocument": { | ||
"Statement": [ | ||
{ | ||
"Action": "sts:AssumeRole", | ||
"Effect": "Allow", | ||
"Principal": { | ||
"Service": "ecs-tasks.amazonaws.com" | ||
} | ||
} | ||
], | ||
"Version": "2012-10-17" | ||
} | ||
} | ||
}, | ||
"TaskDef54694570": { | ||
"Type": "AWS::ECS::TaskDefinition", | ||
"Properties": { | ||
"ContainerDefinitions": [ | ||
{ | ||
"Essential": true, | ||
"Image": "public.ecr.aws/ecs-sample-image/amazon-ecs-sample:latest", | ||
"Name": "Container", | ||
"VersionConsistency": "disabled" | ||
} | ||
], | ||
"Cpu": "256", | ||
"Family": "awsecstaskdefinitioncontainerversionconsistencyTaskDefF7D6E447", | ||
"Memory": "512", | ||
"NetworkMode": "awsvpc", | ||
"RequiresCompatibilities": [ | ||
"FARGATE" | ||
], | ||
"TaskRoleArn": { | ||
"Fn::GetAtt": [ | ||
"TaskDefTaskRole1EDB4A67", | ||
"Arn" | ||
] | ||
} | ||
} | ||
} | ||
}, | ||
"Parameters": { | ||
"BootstrapVersion": { | ||
"Type": "AWS::SSM::Parameter::Value<String>", | ||
"Default": "/cdk-bootstrap/hnb659fds/version", | ||
"Description": "Version of the CDK Bootstrap resources in this environment, automatically retrieved from SSM Parameter Store. [cdk:skip]" | ||
} | ||
}, | ||
"Rules": { | ||
"CheckBootstrapVersion": { | ||
"Assertions": [ | ||
{ | ||
"Assert": { | ||
"Fn::Not": [ | ||
{ | ||
"Fn::Contains": [ | ||
[ | ||
"1", | ||
"2", | ||
"3", | ||
"4", | ||
"5" | ||
], | ||
{ | ||
"Ref": "BootstrapVersion" | ||
} | ||
] | ||
} | ||
] | ||
}, | ||
"AssertDescription": "CDK bootstrap stack version 6 required. Please run 'cdk bootstrap' with a recent version of the CDK CLI." | ||
} | ||
] | ||
} | ||
} | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.