question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Lambda role names are not having `lambdaRole` at the end removed

See original GitHub issue

For some reason starting today when I deploy, the -lambdaRole at the end of the roles is no longer being removed automatically, so many of my functions are hitting the 64 character limit.

I have a feeling it might be because it’s showing my environment now as NodeJS 10.10.0 because I haven’t changed anything else. The weird thing is my node is set to 8.10.0 in provider so not exactly sure what’s going on.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5

github_iconTop GitHub Comments

1reaction
jheckingcommented, Sep 6, 2019

The problem with the “fix” in v2.0.2 is that it simply takes the length of the Ref value to check the role name length, i.e. it literally just adds the length of the string AWS::Region. But of course the reference will be replaced with the actual region name during deployment, e.g. ap-southeast-1 in our case. So we’re still running into the issue with role names exceeding the 64 char limit for certain functions where the role name exceeds that limit but just a few characters.

Is there a way for the plugin to resolve the reference when calculating the role name length? Or can it at least determine the region name specifically?

1reaction
meije702commented, Jun 14, 2019

Having the same issue over here, had to use manual names to circumvent. sls 1.45.1 this plugin: 2.0.1

Read more comments on GitHub >

github_iconTop Results From Across the Web

Lambda execution role - AWS Documentation
A Lambda function's execution role is an AWS Identity and Access Management (IAM) role that grants the function permission to access AWS services...
Read more >
How to specify lambda function and IAM role name in ...
The template does not seem to have a way to define the lambda function name http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws- ...
Read more >
AWS Lambda Guide - Serverless.yml Reference
Can be used to disable the API key without removing it (default: true) ... Configure IAM roles and permissions applied to Lambda functions...
Read more >
Moving Lambda function from Serverless to Terraform
Those who are not too familiar with Lambda function development and deployment ... test-lambda-dev-eu-west-1-lambdaRole # IAM role name terraform import ...
Read more >
AWS IAM Roles - Everything You Need to Know & Examples
Roles do not have passwords or access keys associated with them. ... We will add the Amazon Resource Name (ARN) of the AWS...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found