Improve Container support for AOT publishing and targeting musl runtimes. #37054
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes dotnet/sdk-container-builds#524
Fixes dotnet/sdk-container-builds#301
This PR moves the inference logic that used to be in the targets directly into a task because the logic was getting too gnarly. We now check a number of signals about the project to determine the
required to infer the base image the project should use.
The decision tree looks very similar to before:
ContainerBaseImage
skips this process entirelyaspnet
,runtime
,runtime-deps
, andnightly/runtime-deps
(for aot/extras scenarios) repositories-alpine
variants of these images-aot
or-extras
variants of the image should be usedThe first commit is a refactoring of our tests that used a local registry run inside a Docker container. Recent versions of Docker for Windows have introduced validation that prevent pushing a manifest list tag (i.e. the 6.0 base image tag that contains N image variants for that tag) unless the entire manifest's tags are present in that container. Since we do not test or cover that use case, I slightly refactored the tests to make it easy to just push up the single variants we use.