Skip to content

Commit bc6efb6

Browse files
authored
LAMBJ-151 ARM Layer (#543)
1 parent cb59d1f commit bc6efb6

File tree

4 files changed

+15
-5
lines changed

4 files changed

+15
-5
lines changed

.github/releases/v0.10.0-beta1.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
## Enhancements
22

33
- Uncaught exceptions are now logged as critical errors.
4-
- Exceptions are logged under the "Lambdajection" Log Category, which can be filtered out via ILambdaStartup.ConfigureLogging.
4+
- Exceptions are logged under the "Lambdajection" Log Category, which can be filtered out via ILambdaStartup.ConfigureLogging.
5+
- The Lambdajection Lambda Layer now supports arm64-based lambdas.

src/Layer/Layer.csproj

+9-3
Original file line numberDiff line numberDiff line change
@@ -26,15 +26,21 @@
2626
<ProjectReference Include="../Attributes/Attributes.csproj" PrivateAssets="runtime" />
2727
</ItemGroup>
2828

29-
<Target Name="CreateStore" DependsOnTargets="GetBuildVersion;ResolvePackageAssets">
29+
<ItemGroup>
30+
<LayerArchitectures Include="arm64" />
31+
<LayerArchitectures Include="x64" />
32+
</ItemGroup>
33+
34+
<Target Name="CreateStore" DependsOnTargets="GetBuildVersion;ResolvePackageAssets" Outputs="%(LayerArchitectures.Identity)">
3035
<PropertyGroup>
36+
<CurrentArchitecture>%(LayerArchitectures.Identity)</CurrentArchitecture>
3137
<ReferencePaths>@(ReferencePath, '%253B')</ReferencePaths>
3238
</PropertyGroup>
3339

3440
<ItemGroup>
3541
<StoreArgs Include="--manifest $(MSBuildThisFileDirectory)/Manifest/Manifest.csproj" />
3642
<StoreArgs Include="--output $(OutputPath)/layer" />
37-
<StoreArgs Include="--runtime linux-x64" />
43+
<StoreArgs Include="--runtime linux-$(CurrentArchitecture)" />
3844
<!-- Optimized runtime package stores does not work on .NET 6 -->
3945
<StoreArgs Include="--skip-optimization" />
4046
<StoreArgs Include="/p:Configuration=$(Configuration)" />
@@ -53,7 +59,7 @@
5359
<Exec Command="dotnet store @(StoreArgs, ' ')" StandardOutputImportance="low" />
5460

5561
<ItemGroup>
56-
<Content Include="$(OutputPath)layer/x64/net6.0/artifact.xml" />
62+
<Content Include="$(OutputPath)layer/$(CurrentArchitecture)/net6.0/artifact.xml" Condition="$(CurrentArchitecture) == 'x64'" />
5763
</ItemGroup>
5864
</Target>
5965

src/Layer/Layer.template.yml

+3
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,9 @@ Resources:
2525
Description: Lambda Layer for Lambajection
2626
CompatibleRuntimes:
2727
- provided.al2
28+
CompatibleArchitectures:
29+
- x86_64
30+
- arm64
2831
ContentUri: ./layer
2932
LicenseInfo: MIT
3033

src/Layer/Manifest/Manifest.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22
<PropertyGroup>
33
<TargetFramework>net6.0</TargetFramework>
4-
<RuntimeIdentifier>linux-x64</RuntimeIdentifier>
4+
<RuntimeIdentifiers>linux-x64;linux-arm64</RuntimeIdentifiers>
55
<RestoreLockedMode>false</RestoreLockedMode>
66
<RestorePackagesPath>$(MSBuildThisFileDirectory).nuget</RestorePackagesPath>
77
<RestoreAdditionalProjectSources>$(PackageOutputPath);$(RestoreAdditionalProjectSources)</RestoreAdditionalProjectSources>

0 commit comments

Comments
 (0)