-
Notifications
You must be signed in to change notification settings - Fork 12
/
serverless.yml
47 lines (42 loc) · 1.1 KB
/
serverless.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
service: prisma-serverless
# Use serverless-webpack plugin to transpile ES6/ES7
plugins:
- serverless-dotenv-plugin
- serverless-offline
- serverless-webpack
- serverless-prune-plugin
# Enable auto-packing of external modules
custom:
stage: ${opt:stage}
prune:
automatic: true
number: 5
serverless-offline:
port: 1337
webpack:
webpackConfig: 'webpack.config.js' # Name of webpack configuration file
includeModules: true # Node modules configuration for packaging
packager: 'yarn' # Reserved for future use. Any other values will not work right now.
packExternalModulesMaxBuffer: 204800 # Size of stdio buffers for spawned child processes
provider:
name: aws
runtime: nodejs10.x
cfLogs: true
region: ap-southeast-2
environment: ${file(./config/env.yml)}
package:
individually: true
functions:
graphql:
handler: src/index.handler
events:
- http:
path: /
method: post
cors: true
integration: lambda-proxy
- http:
path: /
method: get
cors: true
integration: lambda-proxy