Skip to content
This repository has been archived by the owner on Jun 6, 2022. It is now read-only.

Placeholder description: @AWare created this with repo-genesis

Notifications You must be signed in to change notification settings

guardian/fulfilment-node-stub-lambda

Repository files navigation

⚠️ SEE FIRST ⚠️

AWS have provided Node 8.10 as a lambda runtime. This somewhat removes the need for babel as it provides async/await out of the box. This repository has not been updated to use the new runtime.

fulfilment-node-stub-lambda

TODO

  • Make this easily deployable in teamcity/riffraff.
  • CODE/PROD seperation
  • Tests

Quick Start!

  1. nvm install 6.10 && nvm use 6.10
  2. yarn
  3. yarn compile && yarn local
  4. fork this repo

package.json

This is responsible for building the lambda, this is a standard npm style package.json. We'll build it with Yarn to ensure versions of dependencies don't change between releases without knowing.

nvm

The latest node runtime available in AWS for lambdas in 6.10. The .nvmrc file will keep you using this when developing.

babel

Turns ES6 into something that will run on aws. (See nvm)

rollup

To run our lambda, we need all the code, including any dependencies in the same place Rollup The lambda environoment includes the aws-sdk, so rollup is told to consider it as an external dependency.

This provides us with a somewhat standard issue lambda environment, and allows you to run the lambda with the yarn local command. Preconfigured to use the membership profile from the normal place. When the file location can be auto-detected, this won't be hardcoded.

This takes our built lambda, and packages it for deployment with riff-raff. It is responsible for the following settings:

  • isAwsLambda
  • cloudformation
  • projectName
  • riffraffFile
  • uploadArtefact

About

Placeholder description: @AWare created this with repo-genesis

Resources

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published