npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

lambda-bundler

v1.1.1

Published

Utility to deploy lambda functions to AWS from the command line

Downloads

24

Readme

lambda-bundler

Utility to deploy lambda functions to AWS from the command line.

Usage

First, ensure your project's main module in question exports a lambda function. That is, your module looks something like:

module.exports = function (event, context, callback) {
  /*...*/
}

And if you have not already, ensure that your AWS credentials are correctly configured.

Then you can simply run from your project root directory to deploy your lambda to AWS:

npm install -g lambda-bundler
lambda-bundler

Alternatively, install as a local dependency to your project and alias to an npm script:

npm install --save-dev lambda-bundler

And in your package.json add the following to your "scripts":

"deploy": "lambda-bundler"

Then you can run:

npm run deploy

Configuration

Configuration of AWS credentials is done via environment variables. The following environment variables are required as a minimum:

export AWS_ACCESS_KEY_ID=[redacted]
export AWS_SECRET_ACCESS_KEY=[redacted]
export AWS_IAM_ROLE=[redacted]

Additionally, the region option can be configured with an environment variable of AWS_REGION.

You may wish to keep these in a .env file in your project (which you should add to .gitignore and NOT check into source control). If you wish to load environment variables from a .env file then these can be loaded automatically by running:

lamdbda-bundler --env .env

Options

All options can be passed as command line flags or defined in a lambda-bundler section of your package.json.

name

String - Defines the FunctionName of your lambda in AWS

Default: the name of your module as defined in package.json

description

String - Defines the decription of your lambda in AWS

Default: the description of your module as defined in package.json

files

Array|String - List of file names (or globs) to be uploaded to AWS as your lambda

Default: ['**/*.js']

Note: package.json is always included in your bundle

ignore

Array|String - List of file names (or globs) of files to be excluded from the bundle

Default: []

Note: node_modules is always ignored

ignoreFile

String - Path to an ignore file

Default: '.lambdaignore'

Note: Passing a value of 'git' or 'npm' will use .gitignore and .npmignore respectively.

region

String - AWS region to load lambda into

Default: process.env.AWS_REGION

role

String - AWS IAM role to use for created lambda

Default: process.env.AWS_IAM_ROLE

envfile

Boolean|String - If set, writes the current set of environment variables to a file and includes it in the bundle. If A string is passed then this defines the filename environment variables will be written to.

Default: false - if set to a truthy, non-string then defaults to '.env'.