Complex pipeline scenarios
Develop and implement complex pipeline scenarios
The objective names hybrid pipelines, VM templates, and self-hosted runners or agents. These are the scenarios where the simple hosted-agent story runs out.
Hybrid: cloud control plane, on-premises execution
The usual shape is Azure Pipelines (or GitHub Actions) orchestrating, while the work runs on machines you own inside your network.
The critical property: the agent initiates the connection outbound. You do not open inbound firewall ports to the internet for the service to reach in. That single fact answers most "how do we deploy on-premises without exposing anything" questions.
Environments with VM resources
Registering VMs as resources in an environment gives you deployment history per
machine and unlocks the rolling strategy — which, as covered elsewhere, is
VM-only. Tags on the VM resources let a deployment job target a subset.
Scaling self-hosted capacity
| Approach | Trade-off |
|---|---|
| Fixed agent pool | Simple; idle cost at trough, queueing at peak |
| VM Scale Set agents | Elastic; you own the scale set |
| Managed DevOps Pools | Elastic; Microsoft manages more of it — current recommendation |
Container jobs and service containers
Running a job in a container pins the toolchain to an image rather than the agent's installed software, which is how you get reproducibility on a self-hosted agent whose machine state persists. Service containers provide dependencies — a database, a message broker — for the duration of the job.
Primary sources