Commit Graph

1 Commits

Author SHA1 Message Date
Maarten 2aca6fb33b Add lab validation tooling: doctor check, deep cleanup, lab-test script
Implements the first wave of lab validation infrastructure:

incusos-proxmox enhancements:
- --doctor flag: standalone environment health check (tool versions,
  IncusOS CDN availability, Proxmox connectivity). Works with or
  without a config file.
- --cleanup --deep: extended cleanup that also removes seed ISOs,
  IncusOS ISOs from Proxmox storage, matching incus remotes, and
  the local ISO cache (~/.cache/incusos-proxmox/iso-cache/).
- --cleanup-all: pool-wide cleanup that destroys ALL VMs with the
  [incusos-lab:managed] marker in the configured resource pool.
  Requires a pool to be set in config for safety scoping.

New script -- lab-test:
- Guided lab validation with 5 phases: deploy & verify, single-node
  workloads (container + VM lifecycle), cluster formation (enable +
  join via incus remotes), cluster workloads (scheduler-placed +
  targeted), and migration & evacuation (stop/move + evacuate/restore).
- Interactive by default with --yes for unattended runs.
- Reports PASS/FAIL/SKIP per test with a summary.
- Supports --dry-run, --skip-deploy, --cleanup, per-phase execution.
- Reads the same YAML config format as incusos-proxmox.

New example configs:
- lab-cluster.yaml: 3-node Incus cluster (VMID 900+) for testing
  clustering, workloads, and migration.
- lab-oc.yaml: Operations Center + 3 Incus nodes (VMID 910+) for
  testing OC-managed provisioning and cluster formation.

Documentation:
- CLAUDE.md: added clustering workflow (incus cluster enable/add/join
  via remotes), lab-test overview, Operations Center CLI notes,
  doctor and cleanup feature descriptions.
- README.md: added lab-test section with usage/phases/options, doctor
  check docs, deep cleanup docs, new example files in listing.
- TESTING.md: added full lab validation guide (quick start, phase-by-
  phase testing, manual cluster formation alternative, OC lab workflow
  with CLI setup and provisioning steps), cleanup instructions.

Not yet tested against live infrastructure -- next step is to deploy
lab-cluster.yaml, add incus remotes, and run lab-test end-to-end.
Known areas to validate: cluster join syntax with remotes, VM nested
virt support, evacuation behavior, apply_defaults consistency across
cluster members.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-19 22:00:05 +01:00