Skip to content

ERROR: CloudFormation cannot update a stack when a custom-named resource requires replacing. Unable to update SSM document. #7

Description

@jeevan-cyriac

Steps to reproduce

Step 1. Create a SSM document using CloudFormation.

  SSMDocumentUpgradeContent: 
    Type: AWS::SSM::Document
    Properties:
      DocumentType: Command
      DocumentFormat: YAML
      Name: 'UpgradeDocument'
      Content:
        schemaVersion: "2.2"
        description: "Upgrade Content to the specified release versions"
        ...
        ...

Step 2. Update the CFN template by modifying the SSM document content

-    description: "Upgrade Content to the specified release versions"
+    description: "<An updated description>"

Expected result

Step 1. Stack creation and SSM document to be created
Step 2. Stack updation and a new SSM document version being created

Actual result

Step 1. The stack deployed fine and the SSM document got created.
Step 2. An error occured - CloudFormation cannot update a stack when a custom-named resource requires replacing. Rename UpgradeDocument and update the stack again.

I want to keep the same custom name for my SSM document on every update and I do not want an auto-generated name. Is this possible via CloudFormation?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions