-
Notifications
You must be signed in to change notification settings - Fork 125
/
template.yaml
42 lines (38 loc) · 1.15 KB
/
template.yaml
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
AWSTemplateFormatVersion: '2010-09-09'
Transform: AWS::Serverless-2016-10-31
Description: >
sam-app
Sample SAM Template for sam-app
Globals:
Function:
Timeout: 10
Resources:
StreamFilesFunction:
Type: AWS::Serverless::Function
Properties:
MemorySize: 512
Handler: run.sh
CodeUri: app/
Runtime: java17
AutoPublishAlias: live
SnapStart:
ApplyOn: PublishedVersions
Environment:
Variables:
RUST_LOG: info
READINESS_CHECK_PATH: /healthz
REMOVE_BASE_PATH: /v1
AWS_LAMBDA_EXEC_WRAPPER: /opt/bootstrap
AWS_LWA_INVOKE_MODE: response_stream
Layers:
- !Sub arn:aws:lambda:${AWS::Region}:753240598075:layer:LambdaAdapterLayerX86:23
FunctionUrlConfig:
AuthType: NONE
InvokeMode: RESPONSE_STREAM
Outputs:
StreamFilesFunctionUrl:
Description: "Function URL for StreamFiles function to stream a dummy 15mb file"
Value: !Sub '${StreamFilesFunctionUrl.FunctionUrl}stream-dummy?size=15'
StreamFilesFunction:
Description: "StreamFilesFunction Lambda Function ARN"
Value: !GetAtt StreamFilesFunction.Arn