{
  "schemaVersion": "ebb.rule.v1",
  "id": "ci-images.azure-pipelines.ubuntu-20.04",
  "ecosystem": "ci-images",
  "purl": "pkg:generic/azure-pipelines/ubuntu-image",
  "affectedVersions": "vers:intdot/20.04",
  "event": "removed",
  "severity": "high",
  "title": "Azure Pipelines Ubuntu 20.04 hosted image is retired",
  "summary": "The Ubuntu 20.04 hosted image was fully removed on 2025-04-30, per the Azure DevOps blog deprecation plan. The Microsoft-hosted agents page lists that image as retired.",
  "replacement": "ubuntu-22.04, ubuntu-24.04, or ubuntu-latest",
  "deadline": "2025-04-30",
  "sources": [
    {
      "title": "Upcoming Updates for Azure Pipelines Agents Images",
      "url": "https://devblogs.microsoft.com/devops/upcoming-updates-for-azure-pipelines-agents-images/",
      "accessedAt": "2026-10-21"
    },
    {
      "title": "Microsoft-hosted agents for Azure Pipelines",
      "url": "https://learn.microsoft.com/azure/devops/pipelines/agents/hosted",
      "accessedAt": "2026-10-21"
    }
  ],
  "provenance": {
    "observedAt": "2026-10-21",
    "reviewedAt": "2026-10-21",
    "reviewer": "arminazimi"
  },
  "migration": {
    "constraints": [
      "Change only Microsoft-hosted pool.vmImage labels. This removal does not apply to self-hosted Ubuntu 20.04 agents.",
      "The Ubuntu 20.04 notice names ubuntu-22.04, ubuntu-24.04, or ubuntu-latest. ubuntu-22.04 is scheduled for removal on 2027-04-17, so prefer ubuntu-24.04 or ubuntu-latest when the workload allows it."
    ],
    "steps": [
      {
        "id": "retarget-vm-image",
        "title": "Retarget the hosted image",
        "instructions": "Change the reported pool.vmImage from ubuntu-20.04 to ubuntu-24.04 or ubuntu-latest (the notice also allows ubuntu-22.04; see the replacement).",
        "targets": "declaration"
      },
      {
        "id": "align-vm-image-surfaces",
        "title": "Align other Azure Pipelines pools",
        "instructions": "Update every other azure-pipelines.yml pool, including stage and job pools, that still pins ubuntu-20.04. Leave self-hosted pool names unchanged.",
        "targets": "all"
      }
    ],
    "verification": [
      {
        "command": "gitlab-ci-lint || circleci config validate",
        "purpose": "Lint .gitlab-ci.yml with gitlab-ci-lint, or .circleci/config.yml with circleci config validate, when the repository has that file. Azure Pipelines has no equivalent local validator: queue the pipeline and confirm the job uses the replacement vmImage."
      }
    ]
  }
}
