aws-cloudformation / aws-cloudformation/cloudformation-coverage-roadmap
Use .mjs extension for nodejs18.x runtime
- Dominant language
- No language data
- Stars
- 1.1k
- Forks
- 62
- PR merge metrics
- No merged PRs in 30d
Description
### Name of the resource
AWS::Lambda::Function
### Resource name
_No response_
### Description
When you include your function source inline with the ZipFile parameter, CloudFormation places it in a file named index and zips it to create a deployment package. CloudFormation automatically adds the .js extension, which is no longer the default for version 18.x.
When creating a Lambda function in the Management Console with Node.js 18.x, an index.mjs is created correctly by default.
It would be nice to see CloudFormation create an index.mjs instead of an index.js when nodejs18.x runtime is defined.
### Other Details
_No response_
Contributor guide
Research direction
Start with the AWS::Lambda::Function resource behavior for inline ZipFile content and the nodejs18.x runtime. Trace where CloudFormation chooses the generated entry-file extension, then verify that nodejs18.x produces index.mjs while other runtimes retain their existing behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, node.js
- Domain
- cloud
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100