Skip to content

Commit e571474

Browse files
committed
API lambda adjustments
1 parent 484338d commit e571474

File tree

3 files changed

+4
-6
lines changed

3 files changed

+4
-6
lines changed

src/api/Elastic.Documentation.Api.Lambda/Elastic.Documentation.Api.Lambda.csproj

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,11 @@
1313
<IsPublishable>true</IsPublishable>
1414
<PublishAot>true</PublishAot>
1515
<PublishTrimmed>true</PublishTrimmed>
16-
1716
<EnableSdkContainerSupport>true</EnableSdkContainerSupport>
1817
<TrimmerSingleWarn>false</TrimmerSingleWarn>
1918
<DockerDefaultTargetOS>Linux</DockerDefaultTargetOS>
20-
<EnableRequestDelegateGenerator>true</EnableRequestDelegateGenerator>
21-
<InterceptorsPreviewNamespaces>$(InterceptorsPreviewNamespaces);Microsoft.AspNetCore.Http.Generated</InterceptorsPreviewNamespaces>
19+
20+
<RootNamespace>Elastic.Documentation.Api.Lambda</RootNamespace>
2221
</PropertyGroup>
2322

2423
<ItemGroup>

src/api/Elastic.Documentation.Api.Lambda/Program.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
var builder = WebApplication.CreateSlimBuilder(args);
1111

1212
builder.Services.AddAWSLambdaHosting(LambdaEventSource.RestApi, new SourceGeneratorLambdaJsonSerializer<LambdaJsonSerializerContext>());
13-
builder.Services.AddElasticDocsApiUsecases(Environment.GetEnvironmentVariable("APP_ENVIRONMENT"));
13+
builder.Services.AddElasticDocsApiUsecases(Environment.GetEnvironmentVariable("ENVIRONMENT") ?? "dev");
1414

1515
var app = builder.Build();
1616

src/infra/docs-lambda-index-publisher/lambda.DockerFile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,5 +31,4 @@ RUN arch=$TARGETARCH \
3131
&& if [ "$arch" = "amd64" ]; then arch="x64"; fi \
3232
&& echo $TARGETOS-$arch > /tmp/rid
3333

34-
RUN dotnet publish src/infra/docs-lambda-index-publisher -r linux-x64 -c Release
35-
34+
RUN dotnet publish src/infra/docs-lambda-index-publisher -r $(cat /tmp/rid) -c Release

0 commit comments

Comments
 (0)