New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

lambdakit

Package Overview
Dependencies
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

lambdakit

A strategy for working with lambdas.

  • 0.0.3
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
2
Maintainers
1
Weekly downloads
 
Created
Source

Lambda kit

A strategy for working with lambdas.

What it does

  • Run Lambdas locally
  • Deploy all Lambdas locally
  • Deploy all Lambdas via CI

This is an opinionated setup for your API, where lambdas reside together. Obviously you could use this and then bring in lambdas as submodules or packages if you wanted to maintain seperate reops.

All assets within the lambda are wrapped up in a ZIP and pushed. Node modules can be easily added. Packages that require more advanced processing may need to be compiled against lambda infrastucture, but this is rare. There are a few built-in Node modules that are available.

Usage

This project has a detailed example in ./example. To run the example, cd into that directory and npm_install and run commands from there.

To run a Lambda

node node_modules/lambdakit --run=weather

Config

  1. Add this to package.json (You can omit if your values are the same as these are defaults).
"lambdakit": {
  "region": "us-east-1",
  "path-to-lambdas": "/lib"
}
  • region the AWS region where your Lambdas reside
  • path-to-lambdas is the path to the folder that holds the lambdas. Currently each folder that holds lambda contents needs to match the lambda name in AWS.
  1. Add config.lambdakit.js for local deploy (You can omit if using local cli config. Contents:
process.env.AWS_ACCESS_KEY_ID = 'XXX';
process.env.AWS_SECRET_ACCESS_KEY = 'XXX';

2b) To deploy on commit from your CI server, install credentials on your project in the CI settings. In the case of CircleCI, it’s done with a URI similar to https://circleci.com/gh/myOrg/myProject/edit#aws

  1. Update your .gitignore to include the following, as your nested lambdas will be projects in and of themselves.
**/node_modules/**
/exports/*
/config.aws.lambda.js

Roadmap

  • Test coverage
  • Compare diff to only push changed lambdas

Keywords

FAQs

Package last updated on 17 Jan 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc