Repository navigation
fix: enforce one workload backend in enclave conformance - #10314
Conversation
Align native conformance and the public environment probe with the single-backend contract while retaining narrowly bounded release-only admission. Local build and tests remain unverified because dependency restoration failed; publish as a draft for review and normal PR CI. Co-authored-by: Copilot App <[email protected]> Copilot-Session: 72a3b55a-ceaf-4f45-9779-26e9eb38904c
Documentation PreviewDocumentation has been built for this PR. To view locally:
Built from commit bd9414d |
Co-authored-by: Copilot App <[email protected]> Copilot-Session: 72a3b55a-ceaf-4f45-9779-26e9eb38904c
Co-authored-by: Copilot App <[email protected]> Copilot-Session: 72a3b55a-ceaf-4f45-9779-26e9eb38904c
✅ Coverage Check PassedOverall Coverage
📁 Per-file Coverage Changes (4 files)
✨ New Files (1 files)
Coverage comparison generated by |
There was a problem hiding this comment.
🟡 Changes recommended
Probe admission and intermediate VM cleanup still prevent the targeted live conformance jobs from completing successfully.
2 open issues
What changed in this PR
Aligns AWF’s native enclave conformance harnesses with the single-workload-backend requirement while retaining release-scoped admission.
Changes:
- Select Cloud Hypervisor for primary and enclave workloads.
- Add bounded conformance admission and preserve workflow identity through sudo.
- Update regression coverage, fixtures, examples and backend guidance.
| File | Description |
|---|---|
src/services/enclave-agent-service.test.ts |
Aligns the gVisor primary fixture. |
src/enclave/preflight.ts |
Enforces backend consistency and conformance admission. |
src/enclave/preflight.test.ts |
Covers Docker-default backend rejection. |
src/enclave/manager.test.ts |
Uses normalized, release-scoped fixtures. |
src/enclave/cloud-hypervisor-conformance-acceptance.ts |
Adds bounded native conformance admission. |
src/enclave/cloud-hypervisor-agent-acceptance.test.ts |
Updates runtime-mismatch expectations. |
src/commands/validators/infrastructure-validator.test.ts |
Replaces incomplete enclave fixtures. |
src/cloud-hypervisor/runtime-validation.ts |
Integrates backend enforcement and admission. |
src/cloud-hypervisor/runtime-validation.test.ts |
Replaces mixed-backend acceptance coverage. |
src/cloud-hypervisor-runtime-backend.env-mapping.test.ts |
Aligns normalized runtime fixtures. |
scripts/ci/test-cloud-hypervisor-enclave-workflow.test.ts |
Checks sudo identity preservation. |
scripts/ci/cloud-hypervisor-enclave-live-smoke.test.ts |
Makes recovery polling deterministic. |
scripts/ci/cloud-hypervisor-enclave-live-smoke.js |
Selects VM primaries and release-matched images. |
scripts/ci/cloud-hypervisor-enclave-environment-probe.test.ts |
Updates probe configuration assertions. |
scripts/ci/cloud-hypervisor-enclave-environment-probe.js |
Adds release wiring and removes the extra mount. |
scripts/ci/cloud-hypervisor-conformance-admission.test.ts |
Exercises generated profiles and admission mutations. |
examples/enclave-environment-probe/README.md |
Documents release-gated probe execution. |
examples/enclave-environment-probe/awf.yaml |
Selects Cloud Hypervisor and proxy infrastructure. |
docs/sbx-integration.md |
Clarifies shared backend requirements. |
docs/cloud-hypervisor-foundation.md |
Updates probe and admission guidance. |
.github/workflows/test-cloud-hypervisor-enclaves.yml |
Preserves admission identity and adds regression coverage. |
Review effort: Max
| || (profile === 'script-only' && entry.script) | ||
| || (profile === 'agent-only' && entry.agent)), | ||
| container: { containerRuntime: 'docker' }, | ||
| container: { containerRuntime: 'cloud-hypervisor', imageTag: artifacts.tag }, |
|
@copilot address review feedback |
Co-authored-by: lpcox <[email protected]>
Addressed in commit |
|
✅ Copilot review passed with no inline comments. @lpcox Add the |

Diagnosis
Fixes a definite configuration blocker reproduced from the release sources used by run 39324827831 at v0.28.67 (
24b5c159c7f6e8a410315942f3214a1c523610ad). The native live harness explicitly selected a Docker primary with Cloud Hypervisor enclaves; the environment-probe example omitted the primary runtime, also selecting Docker by default. Production normalization rejects these configurations with:This error was locally reproduced against the release normalizer, not observed in the removed private stderr of the failed jobs. The original jobs failed before broker readiness; no successful guest acceptance is claimed.
Changes and audit
GITHUB_WORKSPACEwiring for the probe instead of an additional host mount. Enable the mandatory primary API-proxy infrastructure without adding a model credential, agent executor or model call.Public-only data boundaries, credential isolation, private-log disclosure policy, cleanup/recovery and existing invocation/resource/model/time caps are preserved.
CI follow-up
The first PR CI failures were test-fixture regressions, not dependency/build failures: eight manager storage/isolation cases still selected Cloud Hypervisor enclaves with an implicit Docker primary; three enabled-only fabricated enclave objects lacked normalized executors; and the agent-acceptance runtime mutation asserted the later admission error instead of the stronger single-backend rejection. Commit
6142a1e9fixes those five test files using complete normalized same-backend fixtures and the existing narrowly guarded native acceptance context. Commit8c2ff114removes the resulting unusedWrapperConfigtype import reported by ESLint. No production guards or lint rules were weakened.All three requested checks pass on latest head
8c2ff114536355cf6b7c91c67d14b0b3baf4411a, through normal PR synchronize CI:The retained reviewer verified both follow-up exact diffs and source hashes; all ten safety properties passed. Static whitespace and TypeScript syntax checks passed. The worktree is clean. No additional install attempts or manual dispatch/rerun/cancellation were performed for these CI fixes.
Validation and limitations
This PR is intentionally a draft. The user explicitly approved initial publication with local validation blocked.
git diff --check, andnode --checkfor both changed JavaScript harnesses.npm run buildfailed withtsc: command not found.ENOTCONN, followed by npm's internalExit handler never called!error (Node v22.23.3 / npm 10.9.9). The second was the single approved bounded recovery (--maxsockets=1 --fetch-retries=0 --fetch-timeout=30000). Both used--ignore-scripts --no-audit --no-fund, disposable HOME/TMPDIR, no inherited credentials, and the unchanged lockfile. No alternate registry or lifecycle-hook workaround was used.a315239cdid not authorize live acceptance or validate the later fixture commits. Remain draft pending the required release-attested acceptance; this patch does not bypass the published package-matched release/ancestry gate. No merge, release or Agent merge is requested.Prepared in an isolated worktree from current main
2574130a7914d1ece152bfbfd6359110ca8868fb; the original checkout and its unrelated changes were untouched.Authored Markdown security overview