-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathlayer.yaml
51 lines (40 loc) · 1.17 KB
/
layer.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
43
44
45
46
47
48
49
50
51
---
AWSTemplateFormatVersion: "2010-09-09"
Description: "Self-hosted Lambda runtime layer for Golang ARM executables."
Parameters:
ContentS3Bucket:
Type: String
Description: >-
S3 bucket where layer content resides.
Default: "ary.pub-lambda-community"
ContentS3Key:
Type: String
Description: >-
Lambda layer content key path.
Default: "go-arm-lambda/runtime-layer.zip"
Resources:
RuntimeLayer:
Type: AWS::Lambda::LayerVersion
Properties:
CompatibleRuntimes:
- provided.al2
Content:
S3Bucket: !Ref ContentS3Bucket
S3Key: !Ref ContentS3Key
Description: >-
Lambda runtime layer that enables Golang ARM executables.
LayerName: golang-arm-runtime
LicenseInfo: MIT
RuntimeLayerPermisson:
Type: AWS::Lambda::LayerVersionPermission
Properties:
Action: "lambda:GetLayerVersion"
LayerVersionArn: !Ref RuntimeLayer
Principal: !Ref "AWS::AccountId"
Outputs:
RuntimeLayerArn:
Description: >-
ARN of the Lambda layer containing the runtime boostrap.
Value: !Ref RuntimeLayer
Export:
Name: !Sub "${AWS::StackName}:runtime-layer-arn"