feat(podman): honor OCI image working directories - #2563
feat(podman): honor OCI image working directories#2563matthewgrossman wants to merge 14 commits into
Conversation
|
🌿 Preview your docs: https://nvidia-preview-pr-2563.docs.buildwithfern.com/openshell |
a7e1ee7 to
a6993fa
Compare
a6993fa to
a746233
Compare
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
a746233 to
2ab6ea3
Compare
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
|
Label |
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
matthewgrossman
left a comment
There was a problem hiding this comment.
gator-agent
PR Review Status
Validation: This PR is project-valid because it implements maintainer-authored, agent-ready issue #2526 and is scoped to the Podman half of the OCI WorkingDir work after #2530 merged.
Head SHA: 2069f04785a9ae0742057684c25f479176e0902e
Base SHA: 490f66f47af4c225fabeb2dc48ea51c67154827c
Merge base SHA: 490f66f47af4c225fabeb2dc48ea51c67154827c
Patch ID: af1aa85fb495511ae397c200658e15602169ca7b
Gator payload: 2
Review mode: initial
Previous reviewed SHA: none
Blocking findings:
GATOR-2069f047-01: Podman workspace-probe startup recovery can remove containers selected only by the forgeableopenshell.workspace-probe=truelabel.
Carried findings:
- None
Non-blocking suggestions:
- None
Docs: Fern docs and architecture guidance were updated for the user-visible compute-driver behavior.
Next state: gator:in-review
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
matthewgrossman
left a comment
There was a problem hiding this comment.
gator-agent
PR Review Status
Validation: This PR is project-valid because it implements maintainer-authored issue #2526 and extends the merged OCI WorkingDir support to the Podman driver with scoped docs and E2E coverage.
Head SHA: fdf4a19e6fd1b82bfe5a6b8b286e6e8cca433edb
Base SHA: f383ee1038f91921e104405cd01e4150d533fdbe
Merge base SHA: f383ee1038f91921e104405cd01e4150d533fdbe
Patch ID: 897b5986b6d07fd18fe79401e8a6ca725423b9d7
Gator payload: 2
Review mode: follow_up
Previous reviewed SHA: 2069f04785a9ae0742057684c25f479176e0902e
Blocking findings:
- No blocking findings remain.
GATOR-2069f047-01is resolved by the latest probe lifecycle changes: probe names are attempt-unique, ambiguous create conflicts no longer trigger cleanup, and cleanup targets the exact probe name created by this attempt rather than sweeping by a forgeable label.
Carried findings:
- None
Docs: Fern docs and architecture guidance were updated for the user-visible Podman OCI WorkingDir behavior.
E2E: test:e2e is already applied; the required E2E gate is still running.
Next state: gator:watch-pipeline
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Maintainer Approval NeededGator validation and PR monitoring are complete for the current effective patch. Validation: This PR is project-valid because it implements maintainer-authored issue #2526 by extending the merged OCI WorkingDir support to the Podman driver. Human maintainer approval is now required. |
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
matthewgrossman
left a comment
There was a problem hiding this comment.
gator-agent
PR Review Status
Validation: This PR remains project-valid because it implements the Podman portion of maintainer-authored issue #2526 after the Docker predecessor merged.
Head SHA: 02ae9bc8d5b8e841a9fc3d4c8d28551d816dc23c
Base SHA: 170961997fa26cfd7c52a41d302158d0cd0f24b7
Merge base SHA: 170961997fa26cfd7c52a41d302158d0cd0f24b7
Patch ID: eb9b432e24ccaa777624c6138ad18598bd5dfa45
Gator payload: 3
Review mode: follow_up
Previous reviewed SHA: fdf4a19e6fd1b82bfe5a6b8b286e6e8cca433edb
Blocking findings:
- No blocking findings remain. The latest author-only delta was reviewed, and resolved finding
GATOR-2069f047-01remains resolved.
Carried findings:
- None.
Docs: Fern docs, architecture guidance, Podman driver documentation, and companion agent guidance cover the user-visible OCI WorkingDir behavior.
Checks: Required OpenShell / Branch Checks, OpenShell / Helm Lint, and OpenShell / E2E gates are green; DCO passes.
E2E: test:e2e is applied, including successful rootless Podman coverage.
Next state: gator:approval-needed — human maintainer approval is required.
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Review Convergence CheckpointHead SHA: Three finding-bearing review rounds have completed. Root-cause findings:
Scope growth:
Reviewer-quality signals:
Maintainer action: accept the current scope, split follow-up work, waive a finding, or explicitly authorize another autonomous review round. Next state: |
Summary
Extend the OCI working-directory behavior introduced for Docker in #2530 to the Podman driver. Podman sandboxes can now use the non-root
USERand writableWORKDIRalready declared by an ordinary OCI image instead of requiring/sandboxas the single blessed workspace.For a non-default workdir, OpenShell verifies that the final UID, GID, and supplementary groups could already traverse the path and write and enter the directory in the immutable image. Podman then copies the image directory into its persistent workspace volume, and the final supervisor validates the mounted result without creating the path or changing its ownership or mode. An empty workdir,
/, or/sandboxretains the existing OpenShell-managed/sandboxcompatibility behavior.Chronology and scope
USERwhen policy does not provide the corresponding identity field. It removed the requirement for custom images to contain asandbox:sandboxaccount, but deliberately left workspace handling for follow-up work.WORKDIR, verify access as the final identity, grant no new filesystem authority, and preserve/sandboxas the compatibility fallback.This work was originally developed on top of #2530. Both predecessor PRs have merged, and this PR now targets
main.Related Issue
Part of #2526
Changes
/sandboxcompatibility fallbackWhy Podman needs a probe
Docker can validate the image workdir inside the final container because OpenShell does not cover that path with a workspace volume. Podman mounts a persistent named volume directly at the OCI workdir, which hides the original image path before the supervisor starts.
The Podman driver therefore creates a minimal one-shot container from the same pinned image ID, without networking, the workspace volume, secrets, or the sandbox token. The probe assumes the final process identity and asks the kernel whether that identity can traverse every parent and write and enter the original workdir. The probe's normalized identity is passed to the final supervisor as an attestation, and the supervisor checks both that the identity still matches and that Podman's copied-up volume remains accessible. OpenShell fails rather than changing permissions if either check fails.
Testing
mise run pre-commitmise run testCoverage includes image-policy and global-policy identity selection, supplementary groups, resource limits, cancellation, ambiguous creation, exact probe cleanup, nested volumes, permission preservation after copy-up, and forged validation metadata.
Checklist