aws-cloudformation / aws-cloudformation-resource-providers-awsutilities-commandrunner

Apache License 2.0
81 stars 21 forks source link

Template contains errors.: Template format error: Unrecognized resource types: [AWSUtility::CloudFormation::CommandRunner] #42

Closed asrindayananda closed 2 years ago

asrindayananda commented 2 years ago

Hi,

In Cloudformation I keep getting this error

Template` contains errors.: Template format error: Unrecognized resource types: `[AWSUtility::CloudFormation::CommandRunner]

This is my CloudFormation template

AWSTemplateFormatVersion: 2010-09-09
Resources:
  Command:
    Type: 'AWSUtility::CloudFormation::Command'
    Properties:
      Command: aws s3 ls | sed -n 1p | cut -d " " -f3 > /command-output.txt
      Role: <ADDED_IAM_ROLE>
Outputs:
    Output:
        Description: The output of the CommandRunner.
        Value: !GetAtt Command.Output

I have added IAM permissions as per documentation

                  "cloudformation:ValidateTemplate",
                  "cloudformation:GetTemplateSummary",
                  "cloudformation:*",
                  "s3:CreateBucket",
                  "s3:DeleteBucket",
                  "s3:PutBucketPolicy",
                  "s3:PutObject",
                  "cloudformation:RegisterType",
                  "cloudformation:DescribeTypeRegistration",
                  "iam:createRole"
                ],
                "Resource": ["*"]

Tried Role ARN as well

Any help appreciated :)

shantgup commented 2 years ago

Hello, have you installed the resource using the User Installation Steps first?