Skip to content
This repository has been archived by the owner on Feb 1, 2025. It is now read-only.

Commit

Permalink
docs: updated documenation to include deploy command
Browse files Browse the repository at this point in the history
  • Loading branch information
true committed Sep 15, 2022
1 parent 8ecc53f commit 2ac3f3a
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,10 @@ This library uses Cloudfront, S3, ApiGateway and Lambdas to deploy easily in sec

## TL;DR
- In your NextJS project, set output to standalone.
- Run `npx @sladg/nextjs-lambda pack`
- Prepare CDK ([see](#via-cdk))
- Run `cdk deploy`
- Run `next build` (will generate standalone next folder).
- Run `npm run-script env -- next-utils pack` (will create ZIPs).
- Run `npm run-script env -- next-utils deploy` (will deploy to AWS).
- Profit 🎉

## Usage

Expand Down Expand Up @@ -66,7 +67,7 @@ Lambda is designed to serve `_next/image*` route in NextJS stack and replaces th
### Via CDK

See `NextStandaloneStack` construct in `cdk/example.ts`.

Or just use `next-utils deploy` command so you don't have to manage CDK yourself.

#### Benchmark

Expand All @@ -83,6 +84,7 @@ See `NextStandaloneStack` construct in `cdk/example.ts`.
- Run #2 5sec (no changes)
- Run #3 3sec (no changes)
- Run #4 164sec (2min 44sec)
- Run #5 62sec (1min 2sec) (no changes, used `next-utils deploy`)

### Sharp layer

Expand Down

0 comments on commit 2ac3f3a

Please sign in to comment.