Given i have this example template:
{ "AWSTemplateFormatVersion" : "2010-09-09", "Mappings" : { "RegionMap" : { "us-west-1" : { "AMI" : "ami-655a0a20" }, ... } }, "Resources" : { "Ec2Instance" : { "Type" : "AWS::EC2::Instance", "Properties" : { ... }, "DependsOn" : "myDB" }, "myDB" : { "Type" : "AWS::RDS::DBInstance", "Properties" : { ... } }, "myDB2" : { "Type" : "AWS::RDS::DBInstance", "Properties" : { ... } } } }
Is it possible to specify multiple DependsOn in any way? Would be great to have somethink like:
"DependsOn" : ["myDB", "myDB2"]
Whats the normal way?
AWS CloudFormation now supports increased limits on the default number of stacks allowed per AWS account. The number of stacks that can be created in an account is now 2000 (previously 200). CloudFormation allows you to model, provision and manage cloud resources in a safe, predictable, and scalable manner.
You can now deploy CloudFormation Stacks concurrently across multiple AWS regions using AWS CloudFormation StackSets. AWS CloudFormation StackSets announces the ability to deploy CloudFormation Stacks to multiple AWS regions in parallel.
For example, by default, you can only launch 2000 CloudFormation stacks per region in your AWS account.
Yes,
The DependsOn attribute can take a single string or list of strings.
http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-attribute-dependson.html
Syntax:
"DependsOn" : [ String, ... ]
This answer comes up first in Google, so I will include how to do multiple dependson attributes in YAML, which I found in this answer.
AnotherProductionResource: Type: AWS::CloudFormation::Stack Condition: ISProduction DependsOn: - AResource - MyProductionResource Properties: [...]
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With