File tree Expand file tree Collapse file tree 3 files changed +4
-36
lines changed
Expand file tree Collapse file tree 3 files changed +4
-36
lines changed Original file line number Diff line number Diff line change 11FROM mcr.microsoft.com/dotnet/sdk:5.0 AS build
2+ COPY src /app
23WORKDIR /app
34
4- # copy csproj and restore as distinct layers
5- COPY src/*.sln .
6- COPY src/Northwind/*.csproj ./Northwind/
7- COPY src/Northwind.ServiceInterface/*.csproj ./Northwind.ServiceInterface/
8- COPY src/Northwind.ServiceModel/*.csproj ./Northwind.ServiceModel/
95RUN dotnet restore
10-
11- # copy everything else and build app
12- COPY src/Northwind/. ./Northwind/
13- COPY src/Northwind.ServiceInterface/. ./Northwind.ServiceInterface/
14- COPY src/Northwind.ServiceModel/. ./Northwind.ServiceModel/
15- WORKDIR /app/Northwind
166RUN dotnet publish -c Release -o out
177
8+ # Build runtime image
189FROM mcr.microsoft.com/dotnet/aspnet:5.0 AS runtime
1910WORKDIR /app
20- COPY --from=build /app/Northwind/ out ./
11+ COPY --from=build /app/out .
2112ENV ASPNETCORE_URLS http://*:5000
22- ENTRYPOINT ["dotnet" , "Northwind.dll" ]
13+ ENTRYPOINT ["dotnet" , "Northwind.dll" ]
Load Diff This file was deleted.
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments