-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathDockerfile
More file actions
26 lines (16 loc) · 782 Bytes
/
Dockerfile
File metadata and controls
26 lines (16 loc) · 782 Bytes
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
FROM mcr.microsoft.com/dotnet/sdk:6.0 as build
# uses debian based image
WORKDIR /src
COPY ./ ./
RUN dotnet restore ReaderWriter/FileReaderWriterFactoryGRPCWrapper/FileReaderWriterFactoryGRPCWrapper.csproj
COPY . .
RUN dotnet publish --no-restore -c Release --framework net6 -o /published ReaderWriter/FileReaderWriterFactoryGRPCWrapper/FileReaderWriterFactoryGRPCWrapper.csproj
FROM mcr.microsoft.com/dotnet/aspnet:6.0-alpine as runtime
# Uncomment the line below if running with HTTPS
# ENV ASPNETCORE_URLS=https://+:443
ENV GRPC_SERVER_IP=0.0.0.0
ENV GRPC_SERVER_PORT=50051
ENV GRPC_SERVER_AUTOMATED_CACHING_THRESHOLD_BYTES=67108864
WORKDIR /app
COPY --from=build /published .
ENTRYPOINT [ "dotnet", "FileReaderWriterFactoryGRPCWrapper.dll" ]