.NET and ASP.NET Core 10 cheatsheet
.NET and ASP.NET Core 10: Publishing
3 common .NET and ASP.NET Core 10 tasks.
Publish for release
Build in Release mode and write the deployable files to a folder.
dotnet publish -c Release -o out
Publish a self-contained app
Include the runtime, so the target machine needs no .NET install.
dotnet publish -c Release -r linux-x64 --self-contained -o out
Publish as a container image
Build a container image directly from the project, without a Dockerfile.
dotnet publish -t:PublishContainer