GithubHelp home page GithubHelp logo

Comments (4)

sanyamgrover avatar sanyamgrover commented on June 11, 2024 1

from aws-cloudformation-resource-providers-awsutilities-commandrunner.

sanyamgrover avatar sanyamgrover commented on June 11, 2024

@craigataws @shantgup @cfn-rpdk-ci @amazon-auto @sheldonkwoodward

from aws-cloudformation-resource-providers-awsutilities-commandrunner.

maslick avatar maslick commented on June 11, 2024

Please make sure you indent your yaml correctly:

AWSTemplateFormatVersion: 2010-09-09
Parameters:
  Keyid:
    Description: "Key Id for the KMS key to enable key rotation"
    Default: 8eef2781-9753-47fd-9ee4-892f16e3d973
    Type: String
  RegionForKMSkey:
    Description: "Please enter the Region where your KMS key is present"
    Default: us-east-1
    Type: String
  InstanceRole:
    Description: "Please enter the Role Name that Ec2 instance will assume to execute the command"
    Default: ""
    Type: String

Resources:
  Commandrunner:
    Type: "AWSUtility::CloudFormation::CommandRunner"
    Properties:
      Command: !Sub 'aws kms enable-key-rotation --key-id ${Keyid} --region ${RegionForKMSkey} && echo "Key rotation enabled successfully" > /command-output.txt'
    Role: !Ref InstanceRole

Outputs:
  Commands:
    Description: "Echo command Text"
    Value: 
      "Fn::GetAtt": Commandrunner.Output

from aws-cloudformation-resource-providers-awsutilities-commandrunner.

sto-nith avatar sto-nith commented on June 11, 2024

I am facing the same issue "waitcondition timed out. received 0 conditions when expecting 1" while creating a stack with CommandRunner resource.

AWSTemplateFormatVersion: 2010-09-09
Description: >-
  RAP CloudFormation Template. This template is intended for creating stack in
  the existing VPC using current VPC,Internet Gateway and NAT Gateway etc. This
  template will create new routes, security groups, roles, policies, S3 buckets,
  MSK cluster, Redshift cluster etc.
Parameters:
  ENV:
    Type: String
    Description: Environment to run CFN template
    Default: dev
Resources:
  Command:
    Type: 'AWSUtility::CloudFormation::CommandRunner'
    Properties:
      Command: echo Testing 1..2..3 > /command-output.txt

Outputs:
    Output:
        Description: The output of the CommandRunner.
        Value: !GetAtt Command.Output

Did anyone get a resolution to this issue?

from aws-cloudformation-resource-providers-awsutilities-commandrunner.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.