stack/.github/workflows
Bilal Godil d94aa661d8 capture emulator snapshot locally during pull instead of shipping from CI
QEMU migration state isn't portable across accelerators — a KVM-captured
snapshot won't resume under HVF, and `-cpu max` feature sets differ across
hosts. Instead of trying to match every (KVM/HVF/TCG, amd64/arm64)
combination in CI, capture the snapshot on the user's own machine during
`stack emulator pull`: download the qcow2, cold-boot once, wait for all
services, QMP migrate via mapped-ram + multifd, compress. Subsequent
`stack emulator start`s fast-resume in ~3-8s as before.

- Factor qmp_session + capture_vm_state out of build-image.sh into
  common.sh so run-emulator.sh can call them.
- Add cmd_capture to run-emulator.sh. build_qemu_cmd emits the
  resume-compatible device layout (phantom ISOs, no virtfs, fsdev +
  pcie-root-port, pinned 4096MB/4CPU) with -incoming defer gated on an
  actual snapshot being present, so capture mode reuses the same path.
- Capture regenerates runtime-config.iso with STACK_EMULATOR_VM_DIR_HOST
  empty — virtfs is detached for migration compat so /host isn't mounted;
  the `install internal-pck → /host/$VM_DIR_HOST` path would otherwise
  fail and restart-loop stack.service. Mirrors build-image.sh's CI
  runtime.env shape.
- stack-cli `pull` downloads only the qcow2 then invokes run-emulator.sh
  capture. Add --skip-snapshot for CI/debug. startEmulator auto-captures
  on the auto-pull fallback.
- Revert the arm64 CI split: delete qemu-emulator-build-arm64.yaml,
  restore arm64 to the unified matrix on ubicloud-standard-8 under
  cross-arch TCG (macOS HVF runner existed only to produce a portable
  snapshot; no longer needed). Drop savevm.zst from package/upload/publish
  steps; update release notes.

Verified end-to-end on an arm64 Mac under HVF: capture 50s, fast-resume
6.5s, all services green.
2026-04-16 11:12:42 -07:00
..
all-good.yaml Add Claude Code GitHub Workflow (#833) 2025-08-07 18:44:49 -07:00
auto-assign.yaml Run auto-assign on draft PRs 2025-04-10 10:18:47 -07:00
auto-update.yaml Run auto-update only once per day 2025-03-12 17:10:03 -07:00
check-prisma-migrations.yaml Speed up tests (#1063) 2025-12-28 11:25:04 -08:00
claude.yml Upgrade GitHub workflow scripts 2025-11-24 11:21:43 -08:00
db-migration-backwards-compatibility.yaml LLM MCP Flow (#1321) 2026-04-15 17:57:08 +00:00
docker-server-build-push.yaml Email outbox backend (#1030) 2025-12-12 10:26:38 -08:00
docker-server-build-run.yaml Sign up rules (#1138) 2026-02-03 11:08:24 -08:00
e2e-api-tests-local-emulator.yaml LLM MCP Flow (#1321) 2026-04-15 17:57:08 +00:00
e2e-api-tests.yaml LLM MCP Flow (#1321) 2026-04-15 17:57:08 +00:00
e2e-custom-base-port-api-tests.yaml LLM MCP Flow (#1321) 2026-04-15 17:57:08 +00:00
e2e-fallback-tests.yaml LLM MCP Flow (#1321) 2026-04-15 17:57:08 +00:00
lint-and-build.yaml LLM MCP Flow (#1321) 2026-04-15 17:57:08 +00:00
mirror-to-wdb.yaml Upgrade GitHub workflow scripts 2025-11-24 11:21:43 -08:00
npm-publish.yaml stack-cli npm publish 2026-03-13 09:26:12 -07:00
qemu-emulator-build.yaml capture emulator snapshot locally during pull instead of shipping from CI 2026-04-16 11:12:42 -07:00
reviewers-assignees.yml Update review assigner script 2025-09-10 12:05:04 -07:00
setup-tests-with-custom-base-port.yaml Skip setup tests on non-dev branches 2026-04-15 10:21:26 -07:00
setup-tests.yaml Skip setup tests on non-dev branches 2026-04-15 10:21:26 -07:00
swift-sdk-publish.yaml [Fix] [Feat] Update OAuth Sign-In and Get Token Functions to Work (#1130) 2026-01-28 02:17:27 +00:00
sync-main-to-dev.yml Upgrade GitHub workflow scripts 2025-11-24 11:21:43 -08:00
table-of-contents.yaml GH Actions push trigger only on main or dev branches 2025-03-12 10:52:35 -07:00