Updated dotnet core images in DOCKERFILE (#10629)

Since dotnet core 2.2 is out of support I would propose to update script to latest LTS dotnet core version.
This commit is contained in:
Krzysztof Madej 2020-04-14 12:10:48 +02:00 committed by GitHub
parent 9ec7d50eea
commit 97b03523fd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -42,7 +42,7 @@ tutorial](https://www.asp.net/get-started) to initialize a project or clone our
the `Dockerfile` to use the DLL file of your project.
```dockerfile
FROM mcr.microsoft.com/dotnet/core/sdk:2.2 AS build-env
FROM mcr.microsoft.com/dotnet/core/sdk:3.1 AS build-env
WORKDIR /app
# Copy csproj and restore as distinct layers
@ -54,7 +54,7 @@ COPY . ./
RUN dotnet publish -c Release -o out
# Build runtime image
FROM mcr.microsoft.com/dotnet/core/aspnet:2.2
FROM mcr.microsoft.com/dotnet/core/aspnet:3.1
WORKDIR /app
COPY --from=build-env /app/out .
ENTRYPOINT ["dotnet", "aspnetapp.dll"]