Is DependsOn attribute in cloudformation honored on update as well ?

0

Hi,

I have a usecase where resource A DependsOn resource B. Both resources have already been created in my aws account. I want to make a cloudformation change to update both resource A and B and I want that the update is first applied to resource B and then A.

Question: Is the dependency order followed during explicit dependency ?

The AWS docs (https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-attribute-dependson.html) mentions that the order is followed for implicit dependency but it is not clear whether it is followed for explicit dependency as well.

asked 10 months ago448 views
1 Answer
3
Accepted Answer

DependsOn creates explicit dependencies in cloudformation, which means dependency order would be there irrespective of create stack or update stack, because you explicitly dictated CFN to follow that order.

Functions such as Ref, GetAtt create implicit dependencies.

profile pictureAWS
EXPERT
answered 10 months ago
profile pictureAWS
EXPERT
iBehr
reviewed 10 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions