Skip to content

feat(drivers): support docker and podman config mounts#1785

Merged
drew merged 9 commits into
mainfrom
docker-podman-volumes
Jun 10, 2026
Merged

feat(drivers): support docker and podman config mounts#1785
drew merged 9 commits into
mainfrom
docker-podman-volumes

Conversation

@drew

@drew drew commented Jun 5, 2026

Copy link
Copy Markdown
Collaborator

Summary

Adds driver-config mount support for local Docker and Podman sandboxes. Docker accepts existing named volumes and tmpfs mounts; Podman accepts existing named volumes, tmpfs mounts, and image mounts. Host bind mounts remain out of the driver-config schema, and NFS is supported through pre-created runtime-managed named volumes.

Related Issue

N/A. Follow-up to #1744.

Changes

  • Parse and validate per-sandbox mount config for Docker and Podman from --driver-config-json.
  • Validate Docker and Podman named volumes exist before sandbox creation.
  • Add Podman image mount support and image pull handling; keep Docker image mounts unsupported.
  • Document per-driver mount behavior in reference and sandbox management docs.

Testing

  • mise run pre-commit passes
  • Unit tests added/updated
  • E2E tests added/updated (if applicable)

Checklist

  • Follows Conventional Commits
  • Commits are signed off (DCO)
  • Architecture docs updated (if applicable)

@drew drew requested review from a team, derekwaynecarr, maxamillion and mrunalp as code owners June 5, 2026 20:56
@github-actions

github-actions Bot commented Jun 5, 2026

Copy link
Copy Markdown

@drew drew marked this pull request as draft June 5, 2026 21:48
@copy-pr-bot

copy-pr-bot Bot commented Jun 5, 2026

Copy link
Copy Markdown

Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually.

Contributors can view more details about this message here.

Comment thread crates/openshell-driver-docker/src/lib.rs
@drew

drew commented Jun 8, 2026

Copy link
Copy Markdown
Collaborator Author

/ok to test 113bbea

Comment thread docs/reference/sandbox-compute-drivers.mdx
Comment thread crates/openshell-driver-podman/src/container.rs
@drew drew added the test:e2e Requires end-to-end coverage label Jun 9, 2026
@github-actions

github-actions Bot commented Jun 9, 2026

Copy link
Copy Markdown

Label test:e2e applied, but pull-request/1785 is at 113bbea while the PR head is 08b333d. A maintainer needs to comment /ok to test 08b333dd4c8ff2018646bb57aabe7f8abe5890c7 to refresh the mirror. Once the mirror catches up, re-run Branch E2E Checks from the Actions tab.

@drew

drew commented Jun 9, 2026

Copy link
Copy Markdown
Collaborator Author

/ok to test f37da23

@drew drew marked this pull request as ready for review June 10, 2026 00:35
Comment thread crates/openshell-server/src/cli.rs
Comment thread crates/openshell-driver-docker/src/lib.rs Outdated
Comment thread crates/openshell-driver-podman/src/container.rs Outdated
Comment thread crates/openshell-driver-docker/src/lib.rs Outdated
Comment thread crates/openshell-driver-docker/src/lib.rs Outdated
Comment thread crates/openshell-driver-docker/src/lib.rs
Comment thread crates/openshell-driver-docker/src/lib.rs Outdated
Comment thread crates/openshell-driver-docker/src/lib.rs Outdated
Comment thread crates/openshell-driver-docker/src/lib.rs
@benoitf

benoitf commented Jun 10, 2026

Copy link
Copy Markdown
Contributor

hello, FYI I tried in on macOS with a podman machine and I was able to mount my local folder into a work subfolder or /sandbox 👍

@drew

drew commented Jun 10, 2026

Copy link
Copy Markdown
Collaborator Author

Pushed fixes in b00108b.

Addressed the open mount feedback:

  • moved shared protobuf Struct conversion and mount path validation into openshell-core
  • reserved /etc/openshell-tls and shared the reserved target logic across Docker and Podman
  • kept /sandbox exact-only reserved so /sandbox/work remains a supported target
  • changed user bind/volume mounts to default read-only unless read_only: false is explicit
  • gated Docker local-driver bind-backed named volumes behind enable_bind_mounts, using the existing inspect_volume preflight
  • simplified the Docker HostConfig mounts assignment
  • updated driver docs, gateway config docs, and architecture notes for the new defaults and host-path behavior

@drew

drew commented Jun 10, 2026

Copy link
Copy Markdown
Collaborator Author

/ok to test b00108b

@drew drew requested a review from elezar June 10, 2026 17:41
Signed-off-by: Drew Newberry <anewberry@nvidia.com>
drew added 8 commits June 10, 2026 10:42
@drew drew force-pushed the docker-podman-volumes branch from b00108b to f48a9dd Compare June 10, 2026 17:45
@drew drew merged commit 530aaf1 into main Jun 10, 2026
41 checks passed
@drew drew deleted the docker-podman-volumes branch June 10, 2026 18:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

test:e2e Requires end-to-end coverage

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants