Skip to content

About

A tool for running Lambdas locally in order to simulate how they'll work when deployed to AWS with an API Gateway.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Local Lambda Server

runlambdas is a tool for running Node.js Lambdas locally.

This is a fork of the Lambda testing server provided with the Jolt Framework adapted to serve as a standalone CLI tool.

Features:

  • Hot reloading of functions so you don't need to restart the server.
  • Environment variables are made available during function invocation.
  • Supports both synchronous and asynchronous Lambdas.
  • Functions can be nested to support multi-segment paths (ie: GET http://localhost:3001/one/two/myLambda).

Installation:

npm i -g runlambdas`

Usage:

runlambdas functionFolderName [portNumber]
  • A functionFolderName is provided as a relative path. This tells runlambdas where to look for Lambda handlers.
  • Lambda handlers will be loaded based on the request path with the functionFolderName as the root.
    • ie: A request to http://localhost:3001/one/two/myLambda will try to invoke the function at the relative path ./functionFolderName/one/two/myLambda.js.
  • Environment variables (if any are present) are loaded from the .env file located in the same directory as the Lambda at runtime.
  • By default, the server will run on port 3001, but an optional portNumber parameter lets you specify a different port.

About

A tool for running Lambdas locally in order to simulate how they'll work when deployed to AWS with an API Gateway.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages