-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathserverless.yml
42 lines (37 loc) · 1.02 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
service: slack-aws-billing-notification
plugins:
- serverless-python-requirements
- serverless-pseudo-parameters
provider:
name: aws
runtime: python3.7
stage: ops
region: ap-northeast-1
iamRoleStatements:
- Effect: "Allow"
Action:
- "logs:*"
- "cloudwatch:*"
Resource: "*"
environment:
TZ: 'Asia/Tokyo'
SLACK_AWS_BILLING_NOTIFICATION_WEB_HOOK_URL: ${ssm:/slack-aws-billing-notification/web-hook-url}
SLACK_AWS_BILLING_NOTIFICATION_CHANNEL_NAME: ${ssm:/slack-aws-billing-notification/channel-name}
SLACK_AWS_BILLING_NOTIFICATION_ACCOUNT_NAME: ${ssm:/slack-aws-billing-notification/account-name}
custom:
pythonRequirements:
dockerizePip: true
package:
exclude:
- './serverless/**'
- './myvenv/**'
- './node_modules/**'
functions:
function:
handler: src/slack_aws_billing_notification.lambda_handler
timeout: 900
events:
- schedule:
name: 'slack-aws-billing-notification'
rate: cron(0 0 * * ? *)
enabled: true