-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathserverless.yml
34 lines (29 loc) · 958 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
service: ${file(./package.json):name}
frameworkVersion: '3'
useDotenv: true
provider:
name: aws
runtime: nodejs18.x
region: ${env:AWS_REGION}
stage: ${env:ENVIRONMENT}
timeout: 180 # 3 minutes
memorySize: 128 # MB
iamRoleStatements:
- Effect: 'Allow'
Action:
- 'secretsmanager:GetSecretValue'
Resource: 'arn:aws:secretsmanager:${self:provider.region}:${aws:accountId}:*'
environment:
BAMBOOHR_SUBDOMAIN: ${env:BAMBOOHR_SUBDOMAIN}
EMPLOYEE_COUNTRY_FILTER: ${env:EMPLOYEE_COUNTRY_FILTER}
BAMBOOHR_TIME_OFF_OFFICE_CODE: ${env:BAMBOOHR_TIME_OFF_OFFICE_CODE}
SLACK_CELEBRATIONS_CHANNEL_IDS: ${env:SLACK_CELEBRATIONS_CHANNEL_IDS}
SLACK_BANK_HOLIDAYS_CHANNEL_IDS: ${env:SLACK_BANK_HOLIDAYS_CHANNEL_IDS}
SLACK_OFFICE_CHANNEL_IDS: ${env:SLACK_OFFICE_CHANNEL_IDS}
plugins:
- serverless-esbuild
functions:
main:
handler: src/handler.main
events:
- schedule: cron(0 7 ? * MON-FRI *)