Created
May 2, 2019 09:09
-
-
Save ManojNair/22e956f08c8ea7dab766944b67d5340b to your computer and use it in GitHub Desktop.
Dockerfile for ASP.Net Core
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM mcr.microsoft.com/dotnet/core/sdk:2.2 AS build-env | |
WORKDIR /app | |
COPY *.csproj ./ | |
RUN dotnet restore | |
COPY . ./ | |
RUN dotnet publish -c Release -o output | |
# Runtime image | |
FROM mcr.microsoft.com/dotnet/core/aspnet:2.2 | |
WORKDIR /app | |
COPY --from=build-env /app/output . | |
ENTRYPOINT ["dotnet", "LetsCode.dll"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment