Microsoft.NET.Build.Containers 0.4.0

.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.

No packages depend on Microsoft.NET.Build.Containers.

# Microsoft.NET.Build.Containers v0.4.x This is the fourth public release of the .NET SDK containerization feature. This version brings the following new features and enhancements: * [Improved support for loading images into the local daemon](https://github.com/dotnet/sdk-container-builds/pull/323) * [Predefine Conventional Labels from project metadata](https://github.com/dotnet/sdk-container-builds/pull/307) * [Better error messages when the local daemon isn't available](https://github.com/dotnet/sdk-container-builds/pull/319) * [Defined `NetSdkOCIImageBuild` project capability for projects building the image](https://github.com/dotnet/sdk-container-builds/issues/320) * [Labels and Ports are now read from the underlying config correctly](https://github.com/dotnet/sdk-container-builds/issues/332) * [Consistent error messages across the .NET CLI and IDE experiences](https://github.com/dotnet/sdk-container-builds/pull/347) * [Support layer history in created images](https://github.com/dotnet/sdk-container-builds/pull/358) * [Allow setting the `User` metadata for created images](https://github.com/dotnet/sdk-container-builds/pull/374) * [Support creating Windows Containers](https://github.com/dotnet/sdk-container-builds/pull/343) * [Support for .NET 8 conventions around image tags](https://github.com/dotnet/sdk-container-builds/pull/384) * [Default to rootless execution for .NET 8 and beyond](https://github.com/dotnet/sdk-container-builds/pull/393) * [Added support for JFrog Artifactory repositories](https://github.com/dotnet/sdk-container-builds/pull/383) ### Special thanks A big shout-out to [Daniel Kuschny](@danielku15) for his contributions to this release! Daniel investigated and solved some fundamental issues around to how we create archives to send to a local container daemon. He also diagnosed and added support for Artifactory JFrog container registries, as well as implemented support for Windows Containers. To start containerizing your projects, see our [Getting Started](http://github.com/dotnet/sdk-container-builds/blob/main/docs/GettingStarted.md) docs.

.NET 7.0

  • No dependencies.

Version Downloads Last updated
11.0.100-preview.4.26230.115 0 05/12/2026
11.0.100-preview.3.26207.106 4 04/20/2026
11.0.100-preview.2.26159.112 6 03/15/2026
11.0.100-preview.1.26104.118 6 02/21/2026
10.0.300 0 05/12/2026
10.0.204 0 05/12/2026
10.0.203 6 04/28/2026
10.0.202 4 04/20/2026
10.0.201 7 03/14/2026
10.0.200 5 03/15/2026
10.0.108 0 05/12/2026
10.0.107 5 04/28/2026
10.0.106 6 04/20/2026
10.0.105 6 03/14/2026
10.0.104 6 03/14/2026
10.0.103 6 02/20/2026
10.0.102 7 01/14/2026
10.0.101 6 01/14/2026
10.0.100 7 11/14/2025
10.0.100-rc.2.25502.107 8 10/17/2025
10.0.100-rc.1.25451.107 8 09/22/2025
10.0.100-preview.7.25380.108 6 09/29/2025
10.0.100-preview.6.25358.103 8 07/24/2025
10.0.100-preview.5.25277.114 9 06/07/2025
10.0.100-preview.4.25258.110 9 06/07/2025
10.0.100-preview.3.25201.16 10 06/07/2025
10.0.100-preview.2.25164.34 9 06/07/2025
10.0.100-preview.1.25120.13 11 06/05/2025
9.0.314 0 05/12/2026
9.0.313 5 04/20/2026
9.0.312 6 03/14/2026
9.0.311 6 02/20/2026
9.0.310 6 02/20/2026
9.0.309 7 01/14/2026
9.0.308 7 11/21/2025
9.0.307 8 11/14/2025
9.0.306 9 10/17/2025
9.0.305 10 09/15/2025
9.0.304 10 09/15/2025
9.0.303 10 07/24/2025
9.0.302 11 07/14/2025
9.0.301 12 06/12/2025
9.0.300 12 05/31/2025
9.0.205 11 06/12/2025
9.0.204 12 05/29/2025
9.0.203 12 05/29/2025
9.0.202 12 05/29/2025
9.0.201 12 05/29/2025
9.0.200 12 05/29/2025
9.0.200-preview.0.24575.35 9 01/21/2025
9.0.117 0 05/12/2026
9.0.116 5 04/20/2026
9.0.115 6 03/14/2026
9.0.114 6 02/20/2026
9.0.113 7 01/14/2026
9.0.112 8 11/14/2025
9.0.111 9 10/26/2025
9.0.110 10 09/15/2025
9.0.109 10 09/15/2025
9.0.108 11 07/14/2025
9.0.107 12 06/12/2025
9.0.106 13 05/29/2025
9.0.105 12 05/29/2025
9.0.104 12 05/29/2025
9.0.103 11 05/29/2025
9.0.102 12 01/21/2025
9.0.101 12 01/21/2025
9.0.100 12 01/21/2025
9.0.100-rc.2.24474.11 11 01/21/2025
9.0.100-rc.1.24452.12 11 01/21/2025
9.0.100-preview.7.24407.12 9 01/21/2025
9.0.100-preview.6.24328.19 9 01/21/2025
9.0.100-preview.5.24307.3 9 01/21/2025
9.0.100-preview.4.24267.43 9 01/21/2025
9.0.100-preview.3.24204.14 13 04/20/2024
9.0.100-preview.2.24157.36 11 04/20/2024
9.0.100-preview.1.24101.1 12 04/19/2024
8.0.421 0 05/12/2026
8.0.420 4 04/20/2026
8.0.419 6 03/14/2026
8.0.418 6 02/20/2026
8.0.417 7 01/14/2026
8.0.416 8 11/14/2025
8.0.415 8 10/26/2025
8.0.414 10 09/15/2025
8.0.413 10 09/15/2025
8.0.412 11 07/14/2025
8.0.411 12 06/12/2025
8.0.410 13 05/29/2025
8.0.409 12 05/29/2025
8.0.408 12 05/29/2025
8.0.407 12 05/29/2025
8.0.406 12 05/29/2025
8.0.405 12 01/21/2025
8.0.404 12 01/21/2025
8.0.403 12 01/21/2025
8.0.402 12 01/21/2025
8.0.401 12 01/21/2025
8.0.400 12 01/21/2025
8.0.319 8 11/14/2025
8.0.318 9 10/17/2025
8.0.317 10 09/15/2025
8.0.316 10 09/15/2025
8.0.315 11 07/14/2025
8.0.314 12 06/12/2025
8.0.313 12 05/29/2025
8.0.312 12 05/29/2025
8.0.311 12 05/29/2025
8.0.310 12 05/29/2025
8.0.309 12 05/29/2025
8.0.308 13 01/21/2025
8.0.307 12 01/21/2025
8.0.306 12 01/21/2025
8.0.304 12 01/21/2025
8.0.303 13 01/21/2025
8.0.302 12 01/21/2025
8.0.301 12 01/21/2025
8.0.300 13 01/21/2025
8.0.206 12 01/21/2025
8.0.205 12 01/21/2025
8.0.204 14 04/19/2024
8.0.202 13 04/20/2024
8.0.200 14 04/18/2024
8.0.127 0 05/12/2026
8.0.126 4 04/20/2026
8.0.125 6 03/14/2026
8.0.124 6 02/20/2026
8.0.123 7 01/14/2026
8.0.122 8 11/14/2025
8.0.121 8 10/26/2025
8.0.120 10 09/15/2025
8.0.119 10 09/15/2025
8.0.118 11 07/14/2025
8.0.117 12 06/12/2025
8.0.116 12 05/29/2025
8.0.115 12 05/29/2025
8.0.114 12 05/29/2025
8.0.113 13 05/29/2025
8.0.112 12 01/21/2025
8.0.111 13 01/21/2025
8.0.110 12 01/21/2025
8.0.108 12 01/21/2025
8.0.107 12 01/21/2025
8.0.106 12 01/21/2025
8.0.105 11 01/21/2025
8.0.104 15 04/18/2024
8.0.103 14 04/20/2024
8.0.102 14 04/20/2024
8.0.101 14 04/20/2024
8.0.100 14 04/18/2024
8.0.100-rc.2.23480.5 13 04/19/2024
8.0.100-rc.1.23462.41 13 04/19/2024
8.0.100-rc.1.23455.21 13 04/19/2024
8.0.100-preview.7.23376.5 11 04/18/2024
8.0.100-preview.6.23330.7 12 04/20/2024
8.0.100-preview.5.23303.1 12 04/18/2024
8.0.100-preview.4.23260.11 11 04/18/2024
7.0.410 12 01/21/2025
7.0.409 12 01/21/2025
7.0.408 14 04/20/2024
7.0.407 14 04/19/2024
7.0.406 14 04/19/2024
7.0.405 14 04/20/2024
7.0.404 13 04/19/2024
7.0.403 14 04/20/2024
7.0.402 14 04/18/2024
7.0.401 13 04/19/2024
7.0.400 13 04/19/2024
7.0.317 12 01/21/2025
7.0.316 12 01/21/2025
7.0.315 13 04/19/2024
7.0.314 13 04/20/2024
7.0.313 14 04/19/2024
7.0.312 14 04/19/2024
7.0.311 14 04/19/2024
7.0.310 14 04/20/2024
7.0.309 14 04/18/2024
7.0.308 14 04/20/2024
7.0.307 15 04/20/2024
7.0.306 15 08/18/2023
7.0.305 14 04/19/2024
7.0.304 14 04/19/2024
7.0.302 13 04/20/2024
0.4.0 13 04/20/2024
0.3.2 13 04/19/2024
0.2.7 12 01/21/2025
0.1.8 13 04/19/2024