Skip to content

Commit d1a42ef

Browse files
committed
docs: update sails example README with current state
1 parent 554629d commit d1a42ef

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

examples/sails/README.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,27 @@
22

33
a [Sails v1](https://sailsjs.com) application
44

5+
### aws-serverless-express WIP
6+
7+
This example is a WIP which works locally by simulating a Lambda handler invocation, however, in production we're receiving 404 'Cannot GET /'.
8+
9+
This example was created by:
10+
11+
1. Running `npx sails new sails` to generate a starter app
12+
2. Updating `app.js` with:
13+
14+
```js
15+
const appPromise = new Promise((resolve) => {
16+
sails.lift(rc('sails'), () => {
17+
resolve(sails.hooks.http.app)
18+
})
19+
})
20+
21+
module.exports = appPromise
22+
```
23+
1. Adding `lambda.js`, `scripts/local.js`, `api-gateway-event.json`, and `sam-template.yaml`
24+
2. Updating `package.json` with `config` and `scripts`
25+
526

627
### Links
728

0 commit comments

Comments
 (0)