-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathserverless.yml
48 lines (47 loc) · 1.13 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
48
service: on-call-bot-serverless
frameworkVersion: '2'
provider:
lambdaHashingVersion: "20201221"
name: aws
runtime: nodejs14.x
environment:
AWS_NODEJS_CONNECTION_REUSE_ENABLED: 1
stage: ${self:provider.stage}
stage: ${opt:stage, 'dev'}
region: ${opt:region, 'us-east-2'}
memorySize: 256
logRetentionInDays: 5
functions:
slack:
handler: src/app.handler
events:
- http:
path: slack/events
method: post
iamRoleStatements:
- Effect: "Allow"
Action:
- "secretsmanager:GetSecretValue"
Resource:
Fn::Join:
- ':'
- - 'arn:aws:secretsmanager'
- ${self:provider.region}
- Ref: 'AWS::AccountId'
- 'secret'
- 'OncallSlackBot-serverless*'
reservedConcurrency: 1
plugins:
- serverless-webpack
- serverless-iam-roles-per-function
- serverless-offline
package:
excludeDevDependencies: true
# individually: true
custom:
webpack:
webpackConfig: ./webpack.config.js
includeModules: true
# forceExclude:
# - aws-sdk
excludeFiles: src/**/*.test.js