container publishing
Using dotnet publish to build a container image of an app directly, without writing a Dockerfile.
In more detail
dotnet publish -c Release -p:PublishProfile=DefaultContainer produces an image based on a Microsoft .NET base image. Keep the base image, processor architecture and patch policy explicit in the deployment files.
Example
dotnet publish -c Release -p:PublishProfile=DefaultContainerRelated terms
- dotnet publish — The dotnet command that compiles an app and gathers everything needed to run it into a folder or container image, ready to deploy.
- container — A running program that has been fenced off from the rest of the computer so it only sees its own files, network and processes.
- image — A read-only package containing a program and everything it needs to run, used as the template for containers.
- base image — The image a Dockerfile starts from with FROM, which supplies the operating system files and often a language runtime.
Taught in
- OpenTelemetry, Container Publishing and Trimming — Modern .NET Core, C# & Enterprise Microservices