If I'm not wrong, ASP.NET Core projects are .NET Core console applications that set up HTTP Server. It has a Program
class with Main
method. All specified ASP.NET Core namespaces and types are distributed via NuGet packages (referenced in Microsoft.NET.Sdk.Web
SDK).
My logic says me "for running ASP.NET Core apps you only .NET Core runtime", but...
In dotnet download runtime website, there are downloads for .NET Core runtime and for for ASP.NET Core runtime.
In DockerHub, there are a image for .NET runtime and a image for ASP.NET Core runtime.
When I run
dotnet --list-runtimes
, I see:- Microsoft.NETCore.App 5.0.5
- Microsoft.AspNetCore.App 5.0.5
What are the difference between the both runtimes? Can I run ASP.NET application with .NET Core runtime and without ASP.NET Core runtime? In negative case, why specified runtime for ASP.NET Core is needed? I don't need specified runtime for running e.g. Monogame projects.