-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Failed to use basic images correctly #619
Comments
@baronfel Can you help me take a look? |
For multi-arch builds, the base image to use is decided at the 'outer' build layer (where <ContainerBaseImage>mcr.microsoft.com/dotnet/sdk:9.0.200-alpine3.20</ContainerBaseImage> without Conditions in your project file - the SDK tooling takes case of finding the arch-specific variants of that 'image manifest' for you. I just confirmed this testing with your examples. |
For the building of multi - architecture images, its processor architecture is msil. But when it comes to the individual architecture - specific builds, aren't they amd64 and arm64? And since I have used conditions, shouldn't they use my specific base images? Isn't that how it's supposed to be understood? |
What you describe is one way to implement it, but it is not the way we have chosen - we preferred to implement a mechanism that ensures all arch-specific images must be part of the same parent base image, to help ensure that when we stitch together the arch-specific images into one multi-arch manifest the only difference between the images is the architecture. In your example above, you can see that there is already some drift between your two sub-images - they use different OS versions. This is generally not a good thing - the same named image should have all of the same configuration except for the architecture difference. |
I'm sorry, the example I gave above wasn't very good because I used different system versions. I've already updated the example. Actually, what I want to demonstrate with my example is the use of base images for different architectures, rather than a single unified base image. |
I don't believe we support that now - by design. Can you tell me more about when having different base images would be desirable for you? What technical benefits do you get out of it? As far as I've seen, it's kind of an anti-pattern around the container ecosystem. |
Well, you see, before we only released single - architecture images, and we didn't create any statements about it. That's because in many of our previous projects, we used different base images according to the different processors. But now, when we use the SDK to release multi - architecture images, we find that the base image is not what we expect it to be. |
I was getting ready to build a multi-architecture image, but I noticed it wasn't using the correct base image. Instead, it defaulted to the
dotnet/aspnet
image. Here are the steps to reproduce the issue.By the way, I noticed that the image tag is x64 instead of amd64. It would be great if we could use amd64 instead of x64.
Reproduce steps
1.WebApplication1
2.Directory.Build.targets
3.
The text was updated successfully, but these errors were encountered: