Repository navigation
Closed
Description
Parent: #816. Needs: #817, whose init boots a GPT distro and the tmpfs upper. Builds on #813's GPT bindings. Delivers, with #817 and #591's docs: #558.
Goal. nvx-rs sandbox run, provision and start accept every format and upper that the shared plan supports, and refuse a share that reaches the sandbox's own files.
Today (dev c5a0dd7):
--layer ROLE,PATH,EROFS_UUIDnames an EROFSdistroonly, and the CLI plans it over an ext4 scratch (host/cli/sandbox/mod.rs). The library's GPT bindings (sandbox: bind GPT disks, plan adapter launches, and stage registered images #813) are unused by the CLI.runandprovisionverify the layer when a manifest sits beside it.provisionrecords its binding, andstartchecks it without reading the layer again; both launch throughPreparedLaunch(nvx-rs: separate distro verification from launch planning #653, nvx-rs: hand the VMM the checked images of a sandbox launch #752).- The CLI refuses overlapping host paths among a sandbox's own shares, but not a share that reaches its state directory, scratch, layers or bundle.
Scope:
- Formats and uppers: a GPT
distronamed by its disk GUID, and the tmpfs upper, with exactly onenvx_overlay_upper=ramfstoken and no scratch block or token. They are planned through the typed plan forsandbox run,provisionandstart. The option forms are settled in the PR; today's EROFS forms keep their meaning. - Bindings:
provisionrecords a GPT binding (sandbox: bind GPT disks, plan adapter launches, and stage registered images #813) as it records an EROFS one, andstartchecks it by metadata only. A tmpfs sandbox records and claims no scratch. - Protected paths: a share is refused if its host path equals, contains or lies inside the sandbox's state directory, scratch, layers or bundle. Paths are compared by canonical path and by identity, at provision and again at start;
sandbox run, which has no state directory, checks the rest. - Records: the sandbox's records name its format and upper.
Not in scope: guest root assembly (#817); nvx-rs run's shares (#802); protected roots chosen by the library; image management.
Acceptance:
sandbox run,provisionandstarteach boot all four format and upper combinations on KVM, MSHV and WHP. Tests assert the selected filesystem and upper, the expected identities, the block size, and no scratch in RAM mode.- A GPT image that changed after
provisionfailsstartwithout reading content, and a wrong disk GUID fails the assembly. Conflicting upper settings are refused. - Protected-path tests cover a single share, symbolic link, junction and bind-mount aliases, and a state directory created during provision.
- Unchanged cases keep their goldens. Intended changes are limited to the format token, the protected paths and the records.
Carries over: #622's scope 7 (A4 PR 7), apart from the binding that provision already records, and the CLI's part of #622's first acceptance item.
Metadata
Metadata
Assignees
Labels
No labels
Activity
nvx-rs sandbox#853esaurez commentedon Nov 1, 2026
Rescoped by the nvx-rs slimming workstream (#1076).
nvx-rs sandboxgets GPT and EROFS images, a scratch or a RAM upper with its cap (50% of memory by default), and protected paths, checked by canonical path atprovisionand again atstart, on nvx-cli's own store and the new launch APIs. Delivered by #1110 and #1111; image staging and the path rules then move into nvx-cli in #1124 and #1125.sandbox: refuse shares of a sandbox's own files
sandbox: refuse shares of a sandbox's own files
sandbox: refuse shares of a sandbox's own files
sandbox: refuse shares of a sandbox's own files
sandbox: run a workload once through the managed VM API
sandbox: refuse shares of a sandbox's own files
sandbox: run a workload once through the managed VM API
sandbox: refuse shares of a sandbox's own files
sandbox: run a workload once through the managed VM API
sandbox: run a workload once through the managed VM API
sandbox: run a workload once through the managed VM API
ppenna commentedon Nov 13, 2026
Completed on
feature/nvx-refactor, as rescoped above for #1076. The groups that deliver it have merged and closed as completed:provisionrecords a GPT or EROFS image, and a scratch or a RAM upper with its cap, 50% of memory by default, andstartreads them back (SL3.5a, SL3.5a: provision typed EROFS/GPT images and bounded RAM uppers #1466). A share of the sandbox's own files is refused atprovisionand again atstart(SL3.5c, sandbox: refuse shares of a sandbox's own files (SL3.5c) #1485).sandbox run, and one exec at a time #1111:sandbox runtakes the same image and upper options, and refuses the protected paths that apply to it (SL3.4b, sandbox: run a workload once through the managed VM API (SL3.4b) #1490).The options are
--layer-format {erofs,gpt},--upper {scratch,ram}and--ram-upper-percent. As #1110 scoped them, the protected paths are compared after resolution, which follows symbolic links and junctions but not hard links or bind mounts; there is no alias matrix. #1118's twelve cold cells, EROFS and GPT over a scratch or a RAM upper on KVM, MSHV and WHP, run in the public sandbox scenarios.The push CI run at
367f7fe4d0, which contains all of them, passed, including those scenarios: https://github.com/microsoft/nvx/actions/runs/43363710885.devreceives it whenfeature/nvx-refactorlands there.sandbox: refuse shares of a sandbox's own files
sandbox: run a workload once through the managed VM API
sandbox: refuse shares of a sandbox's own files
sandbox: run a workload once through the managed VM API