Sample app targets .NET 7, prerequisite section states .NET 6 which causes an error.
Sample app and docker image target .NET 7, but the prerequisite states .NET 6. This produces an error during the project build and app push to docker.
Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.
- ID: 3653642e-61ef-717b-5436-9bd0a3c4e6f4
- Version Independent ID: 80c1ce51-46fb-0693-525a-7cad37150c7b
- Content: Docker images for ASP.NET Core
- Content Source: aspnetcore/host-and-deploy/docker/building-net-docker-images.md
- Product: aspnet-core
- Technology: aspnetcore-hostdeploy
- GitHub Login: @Rick-Anderson
- Microsoft Alias: riande
The problem is larger than just the 6.0/7.0 difference. There are separate doc pages for each .NET version. So even before the change to make the dotnet-docker samples to be based on .NET 7 instead of .NET 6, there was a problem with the doc pages related to .NET Core 3.1. That's because the 3.1 doc page is referring to the same dotnet-docker repo and so there was a 3.1 pre-requisite on the doc page but the repo was configured to use .NET 6 in the sample projects.
I've outlined some potential solutions at https://github.com/dotnet/dotnet-docker/pull/3989#pullrequestreview-1077365611. PTAL @Rick-Anderson
Moved to #27141