- Dockerfiles and READMEs are generated from templates using Cottle.
- Dockerfile templates are located in the
eng/dockerfile-templatesdirectory - README templates are located in the
eng/readme-templatesdirectory. - Do not edit the Dockerfiles in
src/directly. - To generate Dockerfiles from templates, run
pwsh ./eng/dockerfile-templates/Get-GeneratedDockerfiles.ps1. - Do not edit
*README*.mdfiles directly. - To generate READMEs, run
pwsh ./eng/readme-templates/Get-GeneratedReadmes.ps1. - Use the
dockerfile-and-readme-templatingskill when modifying their Cottle templates.
manifest.jsondescribes the Dockerfiles in this repo and how they should be built, tagged, and published.manifest.versions.jsoncontains product version information used by the Dockerfile templates. It is typically updated using theeng/update-dependenciestool.
- Only build and test images that were changed.
- When changing many images, just build and test a single combination of .NET version and OS as a sanity check.
- To build Dockerfiles, run
pwsh ./build-and-test.ps1 -mode 'Build' -paths '*glob*pattern*'. For example, to build all .NET 9.0 Ubuntu Noble images, run./build-and-test.ps1 -paths '*9.0*noble*'. - To run image tests, run
pwsh ./tests/run-tests.ps1 -paths '*glob*pattern*'. - To run only the pre-build validation tests, run
pwsh ./tests/run-tests.ps1 -paths '*' -TestCategories @('pre-build').
- To add new images or a new Linux distro, use the
image-managementskill.
- Use the
porting-changesskill to port or backport changes between branches. - Use the
resolving-conflictsskill when a merge or cherry-pick has conflicts. - Use the
merge-main-to-nightlyskill when asked to mergemainintonightlyafter a release.
- Sample Dockerfiles and README files are not generated from templates.