-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathserverless.yml
More file actions
68 lines (63 loc) · 1.62 KB
/
serverless.yml
File metadata and controls
68 lines (63 loc) · 1.62 KB
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
service: analytics-tracker
frameworkVersion: '^4.0.0'
build:
esbuild:
bundle: true
minify: false
sourcemap:
type: linked
setNodeOptions: true
external:
- '@aws-sdk/*'
buildConcurrency: 3
package:
individually: false
patterns:
- '!.git/**'
- '!.webpack/**'
- '!node_modules/**'
- '!cdk/**'
- '!*.test.ts'
- '!.gitlab-ci.yml'
plugins:
- serverless-offline
custom:
currentStage: ${opt:stage, self:provider.stage}
serverless-offline:
resourceRoutes: true
useSeparateProcesses: true
httpPort: 4000
host: 0.0.0.0
noPrependStageInUrl: true
# Enhanced v4 features for local development
lambdaPort: 4002 # ! Internal port used by serverless-offline's Lambda runtime; reserver for serverless, set here to 4002 otherwise it will default to 3002.
reloadHandler: true
useChildProcesses: true
printOutput: true
noTimeout: false
provider:
name: aws
runtime: nodejs22.x
stage: ${file(./src/js-helpers/set-stage.js):setStage}
httpApi:
shouldStartNameWithService: true
payload: '2.0'
cors: true
logs:
lambda:
logFormat: JSON
applicationLogLevel: INFO
systemLogLevel: INFO
functions: ${file(./src/js-helpers/load-services.js):functions}
resources:
Resources:
PaypalServiceProxyResource:
Type: AWS::ApiGateway::Resource
Properties:
ParentId:
Fn::GetAtt:
- ApiGatewayRestApi # our default Rest API logical ID
- RootResourceId
PathPart: '{proxy+}' # the endpoint in your API that is set as proxy
RestApiId:
Ref: ApiGatewayRestApi