)]}'
{
  "commit": "3ed413730810ae9ffdacc9094c8cc63ded9f2807",
  "tree": "f4786e749defa5c9ab154b8ddfd5abec888fe62d",
  "parents": [
    "54fb092c19fd7a91da5b6550f20b2c79f1193ee2"
  ],
  "author": {
    "name": "Yun Peng",
    "email": "pcloudy@google.com",
    "time": "Fri Oct 02 16:24:24 2026 +0200"
  },
  "committer": {
    "name": "GitHub",
    "email": "noreply@github.com",
    "time": "Fri Oct 02 14:24:24 2026 +0000"
  },
  "message": "Allow instance groups to change zones when repairing VMs (#2914)\n\n## Summary\n\nEvery Linux and Windows agent VM runs a single job and then powers off\n(`disconnect-after-job\u003dtrue` + `ExecStopPost\u003d/bin/systemctl poweroff`).\nThe instance group then repairs the VM by recreating it, and by default\na repair must recreate the VM **in the same zone**. When that zone runs\nout of capacity, recreated VMs get stuck retrying there\n(`ZONE_RESOURCE_POOL_EXHAUSTED`), even if other zones in the region have\nroom. That\u0027s what happened to `bk-docker-arm64` and\n`bk-testing-docker-arm64` on 2026-10-01: all stuck VMs sat in\nus-central1-c.\n\nThis change sets\n[`--on-repair-allow-changing-zone\u003dyes`](https://cloud.google.com/compute/docs/instance-groups/autohealing-instances-in-migs)\nfor all regional instance groups so a repair can recreate the VM in\nanother zone. GCE requires `--force-update-on-repair` for that, which\nalso makes repaired VMs pick up the group\u0027s latest configuration.\n\n## Changes\n\n- `create_instances.py`: new `on_repair_allow_changing_zone` option.\nWhen it\u0027s set on a regional group, the MIG is created with\n`--force-update-on-repair --on-repair-allow-changing-zone yes`.\n- `instances.yml`: enable it in `default_vm`, so it applies to all\ninstance groups.\n\n## Notes\n\n- This doesn\u0027t reserve capacity, it only avoids getting stuck in one\nzone. Reservations would be needed to hold capacity across recreates.\n- Already enabled manually on `bk-testing-docker-arm64` and\n`bk-docker-arm64`. Other groups get it the next time\n`create_instances.py` recreates them.\n\n## Testing\n\nRan `create_instance_group()` against the real `instances.yml` with\n`gcloud` stubbed out. All 9 groups get both flags on the MIG create\ncommand, and instance templates are unchanged. `black --check` passes.",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "4974d7ab151fea9eb56ebd370f2a1f538f510e69",
      "old_mode": 33261,
      "old_path": "buildkite/create_instances.py",
      "new_id": "00ff0230489e4cd4a5609ac320c4cfe2e87d95e6",
      "new_mode": 33261,
      "new_path": "buildkite/create_instances.py"
    },
    {
      "type": "modify",
      "old_id": "7b3abc3daebc2c93dffa325e941aaaae7b4caceb",
      "old_mode": 33188,
      "old_path": "buildkite/instances.yml",
      "new_id": "c66df03ebd560b5174987045e1fdfb738e41e14e",
      "new_mode": 33188,
      "new_path": "buildkite/instances.yml"
    }
  ]
}
