Microsoft.NET.Build.Containers
10.0.100-preview.4.25255.103
Prefix Reserved
dotnet add package Microsoft.NET.Build.Containers --version 10.0.100-preview.4.25255.103
NuGet\Install-Package Microsoft.NET.Build.Containers -Version 10.0.100-preview.4.25255.103
<PackageReference Include="Microsoft.NET.Build.Containers" Version="10.0.100-preview.4.25255.103" />
<PackageVersion Include="Microsoft.NET.Build.Containers" Version="10.0.100-preview.4.25255.103" />
<PackageReference Include="Microsoft.NET.Build.Containers" />
paket add Microsoft.NET.Build.Containers --version 10.0.100-preview.4.25255.103
#r "nuget: Microsoft.NET.Build.Containers, 10.0.100-preview.4.25255.103"
#addin nuget:?package=Microsoft.NET.Build.Containers&version=10.0.100-preview.4.25255.103&prerelease
#tool nuget:?package=Microsoft.NET.Build.Containers&version=10.0.100-preview.4.25255.103&prerelease
.NET SDK Containers
This package lets you build container images from your projects with a single command.
Getting Started
To build a container from the SDK, add this package and run the publish
command,
specifying the DefaultContainer
PublishProfile. You can learn more about Publish Profiles in the documentation.
>dotnet add package Microsoft.NET.Build.Containers
>dotnet publish --os linux --arch x64 -p:PublishProfile=DefaultContainer
...
Pushed container '<your app name>:<your app version>' to registry 'docker://'
...
Out of the box, this package will infer a number of properties about the generated container image, including which base image to use, which version of that image to use, and where to push the generated image. You have control over all of these properties, however. You can read more about these customizations here.
Note: This package only supports Web projects (those that use the Microsoft.NET.Sdk.Web
SDK) in this version.
Learn more about Target Frameworks and .NET Standard.
-
net10.0
- No dependencies.
GitHub repositories (4)
Showing the top 4 popular GitHub repositories that depend on Microsoft.NET.Build.Containers:
Repository | Stars |
---|---|
microsoft/dotnet-podcasts
.NET reference application shown at .NET Conf featuring ASP.NET Core, Blazor, .NET MAUI, Microservices, Orleans, Playwright, and more!
|
|
asynkron/protoactor-dotnet
Proto Actor - Ultra fast distributed actors for Go, C# and Java/Kotlin
|
|
rstropek/Samples
|
|
richlander/container-workshop
Documents fundamental .NET Container workflows
|
Version | Downloads | Last updated |
---|---|---|
10.0.100-preview.4.25255.103 | 0 | 5/12/2025 |
# Microsoft.NET.Build.Containers 8.0.300
This version brings the following new features and enhancements:
* The SDK will generate additional container metadata labels now.
* The `org.opencontainers.image.base.digest` label will be added to uniquely identify the image used as a base for the application container.
* The `net.dot.runtime.majorminor` label will be added to identify the major and minor version of the .NET Runtime that the application runs against.
* The `net.dot.sdk.version` label will be added to identify the .NET SDK version used to build the application container.
* The SDK can use and produce OCI base image layers, not just Docker base image layers. This will happen automatically based on the kind of base image digest you use.
* The SDK will automatically use the `-extra` variant of base images when the application needs globalization/ICU support. So if you set `<ContainerFamily>jammy-chiseled</ContainerFamily>` and `<InvariantGlobalization>false</InvariantGlobalization>` in your project file, the SDK will behave as if you set `<ContainerFamily>jammy-chiseled-extra</ContainerFamily>` - this ensures that your application has the required ICU/Globalization support libraries.
* The SDK will use the runtime-deps base images for Trimmed applications, in addition to AOT applications.