-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathserverless.yml
More file actions
43 lines (40 loc) · 1012 Bytes
/
Copy pathserverless.yml
File metadata and controls
43 lines (40 loc) · 1012 Bytes
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
service: groceror-users
frameworkVersion: "3"
provider:
name: aws
runtime: python3.12
region: ${opt:region, 'us-east-1'}
stage: ${opt:stage, 'prod'}
environment:
MONGO_URI: ${ssm:/groceror/${self:provider.stage}/MONGO_URI}
iam:
role:
statements:
- Effect: Allow
Action:
- sqs:ReceiveMessage
- sqs:DeleteMessage
- sqs:GetQueueAttributes
Resource:
- ${cf:groceror-infra-${self:provider.stage}.UserEventsQueueArn}
functions:
consumer:
handler: lambda_handler.handler
timeout: 60
memorySize: 256
events:
- sqs:
arn: ${cf:groceror-infra-${self:provider.stage}.UserEventsQueueArn}
batchSize: 10
functionResponseType: ReportBatchItemFailures
package:
patterns:
- "!consumer.py"
- "!main.py"
- "!tests/**"
- "!grafana/**"
- "!prometheus.yml"
- "!docker-compose.yml"
- "!Dockerfile"
- "!requirements-dev.txt"
- "!README.md"