AWS Lambda not receiving parameters passed from custom resource #643
Unanswered
dhirajkhodade
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
❓ Guidance Question
The Question
I am trying to create lambda based custom resource using AWS CDK but the parameters that I am passing to lambda using
ResourcePropertiesare not being received in lambda event object.I am not sure what am I doing wrong.
I am getting below error while deploying stack
CDK Code
lambda function code
lambda log
{ "RequestType": "Create", "ServiceToken": "arn:aws:lambda:us-east-1:XXXX:function:CreateEbInfraDevStack-lcpatcherproviderframeworkon-Nk9Go2S4g4sh", "ResponseURL": "https://cloudformation-custom-resource-response-XXXXXXX", "StackId": "arn:aws:cloudformation:us-east-1:XXXXX:stack/CreateEbInfraDevStack/12f54120-d31c-11eb-a9b3-0e443e7db6f3", "RequestId": "5f24fc02-2cd4-49e4-a61b-3258b7de3fb4", "LogicalResourceId": "EBTestCustomResource", "ResourceType": "AWS::CloudFormation::CustomResource", "ResourceProperties": { "ServiceToken": "arn:aws:lambda:us-east-1:XXXXXX:function:CreateEbInfraDevStack-lcpatcherproviderframeworkon-Nk9Go2S4g4sh", "Region": "us-east-1" } } [ERROR] KeyError: 'EbEnvironmentName' Traceback (most recent call last): File "/var/task/eb_launch_config_patcher.py", line 171, in lambda_handler eb_environment_name = props['EbEnvironmentName']Environment
Other information
I am following this CDK example - https://github.com/aws-samples/aws-cdk-examples/tree/master/typescript/custom-resource
Beta Was this translation helpful? Give feedback.
All reactions