Creation of an AWS CloudFormation stack fails with the template validation error "Invalid template resource property 'XXXXXXX'."

This error most commonly occurs in the following scenarios:

  • The property is misspelled or not supported by CloudFormation.
  • The property is specified outside the Properties object in the template.
  • The property is not supported by the resource.

For example:

  • In this example, the property EC2VpcId is specified outside the Properties object in the template for the resource DBSecurityGroup:

"DBSecurityGroup" : {
      "Type": "AWS::RDS::DBSecurityGroup",
      "DependsOn" : "WebServerSecurityGroup",
      "EC2VpcId" : { "Ref" : "VPC" },
      "Properties": {
           "DBSecurityGroupIngress": { "EC2SecurityGroupName": { "Ref": "WebServerSecurityGroup"} },
           "DBSecurityGroupIngress": { "CIDRIP": "50.00.00.00/32" },
           "GroupDescription" : "My group"
      }
}

  • In this example, the property is included in the Properties object, but EC2Vpcid (lowercase "i") is specified instead of EC2VpcId (capital "I"):

"DBSecurityGroup" : {
      "Type": "AWS::RDS::DBSecurityGroup",
      "DependsOn" : "WebServerSecurityGroup",
      "Properties": {
           "EC2Vpcid" : { "Ref" : "VPC" },
           "DBSecurityGroupIngress": { "EC2SecurityGroupName": { "Ref": "WebServerSecurityGroup"} },
           "DBSecurityGroupIngress": { "CIDRIP": "50.00.00.00/32" },
           "GroupDescription" : "My group"
     }
}

  1. Locate the resource in the template that specifies the property.
  2. Verify that the property is specified inside the properties object for the template, verify that a matching property name is used, and verify that the property is supported for the designated resource.

AWS CloudFormation, stack, create, invalid template resource property, validation fails


Did this page help you? Yes | No

Back to the AWS Support Knowledge Center

Need help? Visit the AWS Support Center.