cloudformation-coverage-roadmap
cloudformation-coverage-roadmap copied to clipboard
AWS::ImageBuilder::Image delete AMI when the stack is deleted
Name of the resource
AWS::ImageBuilder::Image
Resource name
No response
Description
I am using AWS::ImageBuilder::Image through CDK CfnImage, so the please let me know if it's a CDK question.
Currently, AMI are created with AWS::ImageBuilder::Image in the stack. But when the stack is deleted, the AMI is still there. Is this expected ?
I would expect it to be deleted along side with the stack as any other resource type. Or is it possible to have a Rention flag option ?
Other Details
No response
Deletion of underlying resources is supported in CloudFormation now, with the DeletionSettings property on AWS::ImageBuilder::Image. Example:
Image:
Type: AWS::ImageBuilder::Image
Properties:
# Deletes underlying AMIs/containers on replace/delete
DeletionSettings:
ExecutionRole: !Ref 'LifecycleExecutionRole'
...