Skip to content

Commit

Permalink
feat: add sls prd file
Browse files Browse the repository at this point in the history
  • Loading branch information
wbruno committed Jun 4, 2023
1 parent ab45be5 commit c9828c1
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions capitulo_5/5.9.2/resources/serverless.prd.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
provider:
iam:
role:
name: serverless-${self:service}-${self:provider.stage}-role
managedPolicies:
- arn:aws:iam::aws:policy/service-role/AWSLambdaBasicExecutionRole
statements:
- Effect: 'Allow'
Action:
- 'dynamodb:Scan'
- 'dynamodb:Query'
- 'dynamodb:GetItem'
- 'dynamodb:PutItem'
- 'dynamodb:DeleteItem'
Resource:
- 'arn:aws:dynamodb:${self:provider.region}:123:table/Shortener'
- 'arn:aws:dynamodb:${self:provider.region}:123:table/Shortener/index/*'
resources:
Resources:
apiGateway:
apiKeys:
- name: ${self:service}-prd
description: api key para o lambda de prod
environment:
AWS_NODEJS_CONNECTION_REUSE_ENABLED: 1
NODE_ENV: production

0 comments on commit c9828c1

Please sign in to comment.