Pipeline artifacts and templates
MS Learn module: Implement a code workflow in your build pipeline · Learning objectives: publish and consume build artifacts, and factor reusable pipeline logic into templates and parameters.
Overview
Two forces shape a healthy CI pipeline: sharing output (artifacts) between jobs/releases, and sharing logic (templates) across pipelines so a change lands once, everywhere.
Units / lessons covered
- Publishing and downloading build artifacts (publish task, download task)
- Feeding artifacts into release/CD stages
- Step/job/stage templates and
extends - Template parameters with defaults and type checking
Concepts introduced (link to term notes)
Key terms / commands
PublishPipelineArtifact/DownloadPipelineArtifact·actions/upload-artifact·template:/extends:/parameters:
Hands-on / what to try
Publish build output from one job and download it in a second job; then extract the repeated build steps into a templates/build.yml step template and include it from two pipelines.
Exam focus
- Artifacts are how jobs on different agents share files; a later job must explicitly
download. extends:enforces structure;template:just includes — know the difference.- GitHub Actions equivalents:
upload/download-artifact, reusable workflows (on: workflow_call).
Related
Path MOC · set-up-ci-with-azure-pipelines · use-github-actions-for-ci