Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

awsm-images

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

awsm-images

This awsm does image modifications (resizing, etc.) and showcases many of the features and integration points of JAWS:

  • 0.1.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
decreased by-100%
Maintainers
1
Weekly downloads
 
Created
Source

awsm-images

This awsm does image modifications (resizing, etc.) and showcases many of the features and integration points of JAWS:

  • browserify optimization
  • including own version of the aws-sdk
  • ENV var integration into code and exposing via the awsm.json:lambda.envVars extension point
  • Leverage awsm CloudFormation extension points (creates s3 bucket AND sets up fine grain perms)

Quickstart

Goal: Given image url, creates a thumbnail and saves to s3 bucket with the JAWS_DATA_MODEL_STAGE prefix (default jaws env var) and an env var defined by this awsm (IMAGE_RESIZE_BUCKET)

  1. Create a new jaws project. Commit your files to version control so we can do diff later (trust me this is worth it)
  2. Run jaws module install https://github.com/awsm-org/img-resize
  3. This downloads the module, installs its dependencies (via npm), merges in CF resources to project resources-cf.json, merges in CF lambda IAM rules to project resources-cf.json. Cool right?
  4. Run jaws env list <stage> all You will notice how IMAGE_RESIZE_BUCKET is not set.
  5. Run jaws env set <stage> all IMAGE_RESIZE_BUCKET <imgresize.yourdomain.from.new.jaws.project.prompt>
  6. Cd into back/aws_modules/imgresize/thumbnail and run jaws deploy lambda. Note how small the lambda code size is ;). Most of the size is the aws-sdk that can't currently be browserified.
  7. Find an image that is > 100x100 and test the lambda sending json {"url":"url here"}

FAQs

Package last updated on 02 Oct 2015

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