Skip to content

akhileshyolo/nodejs15.2.0-aws-lambda-runtime

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Nodejs version 15.2.0 Custom node runtime for AWS Lambda. 100% compatible with AWS's runtime, with some additional features:

Steps to Use:

  1. Create new function with option : Provide Custom Runtime on AMAZON LINUX 2
  2. Attach the give layer or create your own from above Repo.
    AWS Layer Version ARN: aws:lambda:us-east-1:741365237744:layer:runtime-nodejs15-2-0:1
  3. Create index.js file in the lambda code.
const { exec } = require('child_process');


exports.handler = function (event, context) {
	exec('node -v', (error, stdout, stderr) => {
      if (error) {
        console.error(`exec error: ${error}`);
        return;
      }
      console.log(`stdout: ${stdout}`);
      console.error(`stderr: ${stderr}`);
    });
};
  1. To use a handler, use the full path as a handler.
    Update handler in lambda configuration as: index.handler from hello.handler

About

Custom node runtime for AWS Lambda

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Shell 75.1%
  • Dockerfile 24.9%