-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtemplate.yml
74 lines (66 loc) · 1.88 KB
/
template.yml
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
69
70
71
72
73
74
AWSTemplateFormatVersion: 2010-09-09
Transform: AWS::Serverless-2016-10-31
Description: >
Bun runtime packaged as a Lambda layer.
Parameters:
BunVersion:
Type: String
Description: The version of Bun
Default: 'latest'
Resources:
BunLayerArm64:
Type: AWS::Serverless::LayerVersion
Properties:
LayerName: BunRuntimeArm64
Description: !Sub "Bun runtime v${BunVersion} (ARM64)"
ContentUri: ./bun-layer-arm64.zip
CompatibleArchitectures:
- arm64
CompatibleRuntimes:
- provided
LicenseInfo: https://github.com/sumcoding/bun-runtime/blob/main/LICENSE
RetentionPolicy: Retain
BunLayerX64:
Type: AWS::Serverless::LayerVersion
Properties:
LayerName: BunRuntimeX64
Description: !Sub "Bun runtime v${BunVersion} (x64)"
ContentUri: ./bun-layer-x64.zip
CompatibleArchitectures:
- x86_64
CompatibleRuntimes:
- provided
LicenseInfo: https://github.com/sumcoding/bun-runtime/blob/main/LICENSE
RetentionPolicy: Retain
BunLayerX64VersionPermission:
Type: AWS::Lambda::LayerVersionPermission
DeletionPolicy: Retain
UpdateReplacePolicy: Retain
Properties:
Action: lambda:GetLayerVersion
LayerVersionArn: !Ref BunLayerX64
Principal: '*'
BunLayerArm64VersionPermission:
Type: AWS::Lambda::LayerVersionPermission
DeletionPolicy: Retain
UpdateReplacePolicy: Retain
Properties:
Action: lambda:GetLayerVersion
LayerVersionArn: !Ref BunLayerArm64
Principal: '*'
Outputs:
BunVersion:
Description: The version of Bun
Value: !Ref BunVersion
Export:
Name: BunVersion
BunLayerArm64:
Description: Bun runtime (ARM64)
Value: !Ref BunLayerArm64
Export:
Name: BunLayerArm64
BunLayerX64:
Description: Bun runtime(x64)
Value: !Ref BunLayerX64
Export:
Name: BunLayerX64