FROM mcr.microsoft.com/dotnet/core/sdk:3.1 as builder WORKDIR /Result COPY Result/Result.csproj . RUN dotnet restore COPY /Result . RUN dotnet publish -c Release -o /out Result.csproj # app image FROM mcr.microsoft.com/dotnet/core/aspnet:3.1 WORKDIR /app ENTRYPOINT ["dotnet", "Result.dll"] COPY --from=builder /out .