Add "bootstrap" option to ImageBuilder unofficial pipeline #1947
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.
Background: Testing ImageBuilder changes end-to-end (code + pipelines) requires building and pushing an image to a registry and manually updating the ImageBuilder code reference for every code change. This limits how quickly you can iterate on larger ImageBuilder changes.
This PR: adds a bootstrapImageBuilder parameter to the imagebuilder-unofficial pipeline. When enabled, ImageBuilder is built from source at the start of every job. This enables validating ImageBuilder source changes and pipeline template changes together in a single pipeline run.
Linux builds the container directly using
docker build, tags the image, and overrides the imagebuilder image variable so that it's used for later steps. Windows builds directly using .NET, and puts the output in the place that subsequent steps expect. In this sense, it's different from the pipeline build, since it's not built using ImageBuilder. That's why it's a "bootstrap". I determined that this would be OK because the pipeline itself will then proceed to validate that build ImageBuilder can build ImageBuilder.Other options I considered:
Other changes:
init-docker-linuxandinit-docker-windowstemplates into one.Testing: