To start deploying on Docker we need a sample project. I will use the default ASP.NET Core API project. You can create the project by the dotnet new webapi -o MyWebApp command in the terminal. You can publish the application as a self-contained application or framework-dependent.
https://itnext.io/smaller-docker-images-for-asp-net-core-apps-bee4a8fd1277
origin - https://www.pipiscrew.com/2020/02/smaller-docker-images-for-asp-net-core-apps/ smaller-docker-images-for-asp-net-core-apps