amazon.aws
amazon.aws copied to clipboard
Support for IncludeNestedStacks in cloudformation
SUMMARY
Please support the IncludeNestedStacks option for creating changesets in the amazon.aws.cloudformation module
ISSUE TYPE
- Feature Idea
COMPONENT NAME
amazon.aws.cloudformation
ADDITIONAL INFORMATION
It would be nice if the amazon.aws.cloudformation module supported the IncludeNestedStacks option when generating change sets. Documentation here... https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/cloudformation.html#CloudFormation.Client.create_change_set - it allows change sets to be formed for nested stacks. I am not sure about the best way to implement this, because it is configuration specific to change set creation (would not apply during the stack creation phase). Below is an example of how it might work.
Verified (per link above) that this functionality is supported in boto3. I'm happy to work on a PR if no one else is working on this or has interest, but would likely need some hand-holding to get it across the finish line.
cloudformation:
stack_name: test
create_changeset: true
include_nested_stacks: true
state: present
@jillr @tremble What do you think of this feature idea?
I've not used CloudFormation recently enough to be sure what practical impact this will have on the representation, but I'm not opposed to the idea.
What's the difference between how the module works today and how you want it to work?
I can deploy stacks with nested stacks. The module creates and applies the change-set(s) for me. It all works fine.
The only issue is that the module seems to be marked as changed, even when I change nothing. (i.e. it's not idempotent). Looking at the AWS console, the parent stack updated each child stack, but the console says the child stacks weren't changed. Is that a bug in the CloudFormation API that will be fixed with this new flag that you want to add?
+1 for this feature. Defining create_changeset: true is not working for nested stacks at the moment, but as @aarongundel mentioned it is supported in boto3.
@mdavis-xyz Without IncludeNestedStacks: true
changeset always shows that all the nested stacks of the root stack are going to be updated. Even if you made no changes.