Created
March 9, 2022 22:13
-
-
Save awswithdotnet/cddba3d0de2b26892321696a289cdb8f to your computer and use it in GitHub Desktop.
minimalapi Dockerfile
This file contains 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/sdk:6.0 AS sdk | |
WORKDIR /app | |
COPY ./ ./ | |
RUN dotnet publish -c Release -o out | |
FROM mcr.microsoft.com/dotnet/aspnet:6.0 | |
WORKDIR /app | |
COPY --from=sdk /app/out . | |
ENTRYPOINT ["dotnet", "MinimalApi.dll"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment