Skip to content

UROjQ6r80p/pnpm-aws-monorepo

Repository files navigation

Working pnpm monorepo for AWS Lambda

on Linux:

  • git clone https://github.com/UROjQ6r80p/pnpm-aws-monorepo
  • cd pnpm-aws-monorepo
  • pnpm install
  • cd services/aws-lambda
  • pnpm --filter=aws-lambda --prod deploy dist
  • cd dist
  • zip --symlinks -r dist.zip ./
  • Upload dist.zip to aws lambda.

No node-linker=hoisted, default pnpm config used.

No unneccessary modules from other packages bloating your lambda.

image

Lambda:

image

on Windows (zip tools do not support symlinks on Windows)

  • download 7zip
  • git clone https://github.com/UROjQ6r80p/pnpm-aws-monorepo
  • cd pnpm-aws-monorepo
  • pnpm install
  • cd services/aws-lambda
  • pnpm --filter=aws-lambda --prod deploy dist
  • zip a -snl -ttar dist dist/ will be saved to dist.tar
  • copy dist.tar to Linux system. I use WSL
  • on Linux unpack tar tar -xvf dist.tar
  • cd dist
  • zip --symlinks -r dist.zip ./
  • Upload dist.zip to AWS Lambda.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published