Repository navigation
Closed
Labels
Description
Describe the Problem
Some customers have expressed the desire for accessing old versions of samples in the dotnet/samples repo. We want .NET 8.0 samples to be compatible with older samples versions but still want to publish new samples with the latest .NET Docker features/best practices.
Proposal
- Keep both
dotnetappandaspnetappsamples in the samedotnet/samplesrepo. This promotes visibility between different types of samples and also allows us to introduce more types of samples in the future with less overhead. - Keep the floating tags published using traditional, rootful containers with a shell.
- Consider moving to non-root or distroless for a future release.
- Add a new tag with a version suffix to all samples. This can be undocumented if necessary.
- The new full tag structure would be
(sample app name)-(optional sample variant)-(.NET major version)-(os)-(arch). - For each versioned tag, there should also be a floating versionless tag that we will point customers to.
(sample name)-(variant)
- The new full tag structure would be
Tags
I have provided several examples of the proposed tagging scheme below. The list is not exhaustive, the idea is just to provide some examples of how we could publish different types of samples with this naming scheme.
| Old Tags | New Tags | OS |
|---|---|---|
aspnetapp, aspnetapp-alpine-amd64 |
aspnetapp, aspnetapp-8.0, aspnetapp-8.0-alpine3.18, aspnetapp-8.0-alpine3.18-amd64 |
Alpine 3.18 |
| Not published | aspnetapp-composite, aspnetapp-composite-8.0, aspnetapp-8.0-jammy-chiseled, aspnetapp-8.0-jammy-chiseled-amd64 |
Jammy Chiseled |
| Not published | aspnetapp-aot, aspnetapp-aot-8.0, aspnetapp-aot-8.0-jammy-chiseled, aspnetapp-aot-8.0-jammy-chiseled-amd64 |
Jammy Chiseled |
| Not published | aspnetapp-chiseled, aspnetapp-chiseled-8.0...OR aspnetapp-distroless, aspnetapp-distroless-8.0... |
Jammy Chiseled |
| etc. | ||
dotnetapp |
dotnetapp, dotnetapp-alpine?, dotnetapp-8.0, dotnetapp-8.0-alpine3.18, dotnetapp-8.0-alpine3.18-amd64 |
Alpine 3.18 |
| Not published | dotnetapp-ubuntu-chiseled?, dotnetapp-8.0-jammy-chiseled, dotnetapp-8.0-jammy-chiseled, dotnetapp-8.0-jammy-chiseled-amd64 |
Jammy Chiseled |
| Not published | dotnetapp-aot, dotnetapp-aot-8.0, dotnetapp-aot-8.0-jammy-chiseled, dotnetapp-aot-8.0-jammy-chiseled-amd64 |
Jammy Chiseled |
Metadata
Metadata
Assignees
Labels
Type
Projects
- StatusShow more project fieldsDone
Activity
lbussell commentedon Oct 11, 2023
Updated the tag listings to include OS versions.
lbussell commentedon Nov 17, 2023
Here is a greatly simplified proposal based on working with @richlander:
aspnetapp,aspnetapp-alpine-<arch>aspnetapp,aspnetapp-8.0,aspnetapp-8.0-alpine-<arch>aspnetapp-chiseled,aspnetapp-chiseled-8.0,aspnetapp-chiseled-8.0-<arch>dotnetapp,dotnetapp-alpine-<arch>dotnetapp,dotnetapp-8.0,dotnetapp-8.0-alpine-<arch>dotnetapp-chiseled,dotnetapp-chiseled-8.0,dotnetapp-8.0-chiseled-<arch>The intention of having a versioned multi-platform tag (e.g.
aspnetapp-8.0) is so that in the future, it would be easy to compare samples across .NET versions to see startup time and/or size differences, using a simple and accessible tag. I am not super attached to that idea so I could be convinced to remove it.lbussell commentedon Jan 11, 2024
[Triage] After some discussion, we think it would be best to leave Alpine as default so that users can inspect the image with a shell. The Chiseled samples should not be shipped with the addition of a shell since that is a design goal for the Chiseled images and we want to accurately portray the final product that a user might get when using them.
richlander commentedon Jan 16, 2024
Agree. I key change we need is to set the
USERin theaspnetappsample.lbussell commentedon Jan 18, 2024
[Triage] We should leave the user as
rootin .NET 8 and switch it to non-root in .NET 9.lbussell commentedon Feb 14, 2024
Versioned samples and Ubuntu Chiseled are now available with #5185
https://mcr.microsoft.com/en-us/product/dotnet/samples/about
docker pull mcr.microsoft.com/dotnet/samples:aspnetapp-chiseled-8.0