Sending response back to CFN custom resource from python Lambda function

This post has been moved to pprakash.me

Visit –> https://pprakash.me/tech

Advertisements

4 thoughts on “Sending response back to CFN custom resource from python Lambda function

  1. Can this example be tested in the Lambda Function console?
    I am getting error:
    Traceback (most recent call last):
    File “/var/task/PythonCFN.py”, line 11, in lambda_handler
    sendResponse(event, context, responseStatus, responseData)
    File “/var/task/PythonCFN.py”, line 17, in sendResponse
    ‘StackId’: event[‘StackId’],
    KeyError: ‘StackId’

    what am i missing?

    Like

    1. Hi,

      How did you configure your test event? Preferably select “CloudFormation create event” as the event source and update the parameters as used in the python script.

      You don’t have event[‘StackId’] parameter set in your test event hence it’s failing with that error.

      Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s