Author : DevNet

I created the default REST API in NET 5 using Visual Studio 2019. I added Dockerfile like below # https://hub.docker.com/_/microsoft-dotnet-core FROM mcr.microsoft.com/dotnet/sdk:5.0 AS build WORKDIR /source # copy csproj and restore as distinct layers COPY *.sln . COPY doma_api/*.csproj ./doma_api/ RUN dotnet restore # copy everything else and build app COPY doma_api/. ./doma_api/ WORKDIR /source/doma_api ..

Read more