-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathtemplate.yaml
40 lines (34 loc) · 1.16 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
AWSTemplateFormatVersion: '2010-09-09'
Transform: AWS::Serverless-2016-10-31
Description: .NET Lambda Demo
Globals:
Function:
Timeout: 20
Resources:
HelloWorldFunction:
Type: AWS::Serverless::Function
Properties:
CodeUri: src/HelloWorldFunction
Handler: HelloWorldFunction::HelloWorldFunction.Function::FunctionHandler
Runtime: dotnet6
MemorySize: 512
Layers:
- !Sub arn:aws:lambda:${AWS::Region}:580247275435:layer:LambdaInsightsExtension:14
Policies:
- CloudWatchLambdaInsightsExecutionRolePolicy
Events:
HelloWorld:
Type: Api
Properties:
Path: /hello
Method: get
Outputs:
HelloWorldFunctionApi:
Description: "API Gateway endpoint URL for Prod stage for HelloWorldFunction"
Value: !Sub "https://${ServerlessRestApi}.execute-api.${AWS::Region}.amazonaws.com/Prod/hello/"
HelloWorldFunctionArn:
Description: "HelloWorldFunction Lambda Function ARN"
Value: !GetAtt HelloWorldFunction.Arn
HelloWorldFunctionnIamRole:
Description: "Implicit IAM Role created for HelloWorldFunction"
Value: !GetAtt HelloWorldFunctionRole.Arn