-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathserverless.yml
45 lines (41 loc) · 959 Bytes
/
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
# NOTE: update this with your service name
service: tablesfortwo-notifier
# Use the serverless-webpack plugin to transpile ES6
plugins:
- serverless-webpack
- serverless-prune-plugin
- serverless-plugin-aws-alerts
# serverless-webpack configuration
# Enable auto-packing of external modules
custom:
webpack:
webpackConfig: ./webpack.config.js
includeModules: true
alerts:
topics:
alarm: ${file(./env.yml):prod.AWS_SNS_ALARMS_ARN}
alarms:
- functionErrors
provider:
name: aws
runtime: nodejs8.10
stage: prod
region: us-east-1
memorySize: 128
timeout: 30
versionFunctions: true
environment: ${file(./env.yml):prod}
iamRoleStatements:
- Effect: "Allow"
Resource: "*"
Action:
- "sns:*"
functions:
main:
handler: handler.handle
events:
- schedule:
name: tablesfortwo-cron
rate: cron(0 14 ? * WED *) # 2pm Wed
alarms:
- functionErrors