You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: crates/openshell-driver-docker/README.md
+8-6Lines changed: 8 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -91,7 +91,7 @@ contract:
91
91
|`restart_policy = unless-stopped`| Keeps managed sandboxes resumable across daemon or gateway restarts. |
92
92
|`PidsLimit`| Enforces the sandbox PID budget at the Docker cgroup layer. Set `[openshell.drivers.docker].sandbox_pids_limit = 0` to inherit the Docker/runtime default. |
93
93
| CDI GPU request | Uses opaque `driver_config.cdi_devices` values when set; otherwise selects the requested count of NVIDIA CDI GPUs in round-robin order when daemon CDI support is detected. Docker daemon `/info` can permit `nvidia.com/gpu=all` as a WSL2 all-only compatibility fallback, where it counts as one selectable device. Exact CDI device lists must not contain duplicates and must match the effective GPU count. |
94
-
| CDI context upload| For GPU/CDI sandboxes only, mounts daemon-reported CDI spec directories read-only under`/run/openshell/supervisor/cdi-specs/<n>` and uploads `/run/openshell/supervisor/cdi-context.json` after container create and before start. |
94
+
| CDI context mount| For GPU/CDI sandboxes only, creates a gateway-owned context file and bind-mounts it read-only at`/run/openshell/supervisor/cdi-context.json`; daemon-reported CDI spec directories are mounted read-only under `/run/openshell/supervisor/cdi-specs/<n>`. |
95
95
96
96
The agent child process does not retain these supervisor privileges.
97
97
@@ -102,11 +102,13 @@ CDI device IDs from `driver_config.cdi_devices` or the daemon's discovered CDI
102
102
inventory, then passes the same IDs to Docker with a CDI `DeviceRequest`.
103
103
104
104
When a GPU/CDI request is present, the driver also mounts the Docker
105
-
daemon-reported `Info.CDISpecDirs` into supervisor-only paths and uploads a
106
-
small versioned CDI context through Docker's container archive API. The context
107
-
uses container-side spec paths for resolution and keeps host-side spec sources
108
-
diagnostic-only. If the upload fails, the driver removes the created container
109
-
and sandbox token file before reporting the failure.
105
+
daemon-reported `Info.CDISpecDirs` into supervisor-only paths. Before container
106
+
creation, it writes a small versioned CDI context in gateway-owned state and
107
+
bind-mounts it read-only into the supervisor. The context uses container-side
108
+
spec paths for resolution and keeps host-side spec sources diagnostic-only. If
109
+
context or token creation fails, the driver removes any created state files; if
110
+
container creation or start fails, it also removes the container and state
111
+
files before reporting the failure.
110
112
111
113
The sandbox supervisor resolves the selected IDs from those mounted specs
112
114
before it launches agent processes. CDI device nodes become read-write
0 commit comments