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
{{ message }}
Repository navigation
Commit 47f009b
Browse filesBrowse the repository at this point in the historyBrowse files
settings, logs, watch streams, and relay forwarding.
12
18
- Serve HTTP endpoints for health, WebSocket tunnels, and edge-auth flows.
@@ -316,19 +322,18 @@ identity inspection without client-side token decoding.
316
322
Sandbox secrets are gateway-signed JWTs bound to a single sandbox ID. Docker,
317
323
Podman, and VM drivers deliver the initial token through supervisor-only
318
324
runtime material; Kubernetes supervisors exchange a projected ServiceAccount
319
-
token through `IssueSandboxToken`. The gateway delegates that opaque credential
320
-
to the selected compute driver's `AuthenticateSandbox` RPC. A capable driver
321
-
returns the authenticated sandbox ID and an opaque runtime identity. The
322
-
gateway requires both a matching durable sandbox record and the exact
323
-
driver/runtime identity recorded at provisioning before returning the current
324
-
generation-bound session JWT. Session authentication checks the durable runtime
325
-
generation and token lineage for every sandbox RPC, so a replaced runtime and
326
-
legacy unbound tokens cannot retain provider or control-plane access. The
327
-
Kubernetes driver uses its own named configuration to run TokenReview and
328
-
verify the live pod and controlling Sandbox CR. Its runtime identity binds the
329
-
namespace, immutable Sandbox CR UID, and supervisor Pod UID. Restart preserves
330
-
the namespace and CR UID, rejects ambiguous label matches, and rotates only the
331
-
Pod-bound portion of the identity. The bootstrap path accepts
325
+
token through `RegisterSupervisor` to receive their runtime assignment and
326
+
in-memory authentication bundle. `IssueSandboxToken` remains available for
327
+
existing bootstrap clients. The gateway delegates that opaque credential
328
+
to the selected compute driver's `AuthenticateSandbox` RPC. The gateway requires
329
+
a matching durable sandbox record and the exact driver/runtime assignment
330
+
recorded at provisioning before returning operational credentials. Session
331
+
authentication checks the durable runtime generation and token lineage for every
332
+
sandbox RPC, so a replaced runtime and legacy unbound tokens cannot retain
333
+
provider or control-plane access. The Kubernetes driver uses its own named
334
+
configuration to run TokenReview and verify the live proxy Pod, workload Pod,
335
+
and controlling Sandbox CR. The runtime assignment binds their immutable
336
+
Kubernetes identities. The bootstrap path accepts
332
337
both `agents.x-k8s.io/v1beta1` ownerReferences from newer Agent Sandbox
333
338
controllers and `agents.x-k8s.io/v1alpha1` ownerReferences from existing
334
339
deployments. Supervisors renew gateway JWTs in memory before expiry only while
@@ -470,6 +475,11 @@ The storage schema is intentionally narrow:
470
475
471
476
Public RPC contracts and durable protobuf formats have separate ownership. The `openshell.v1.OpenShell` service's request and response roots, streaming flags, and transitive message closure come from the public descriptor set generated by `openshell-core`. The `public_and_durable_schema_inventories_are_complete` test in `openshell-server` owns the counts and fingerprints and requires this inventory to be reviewed whenever it changes. Compute-driver, credential-driver, gateway-interceptor, and supervisor-middleware services are compiled contracts for internal extension boundaries.
472
477
478
+
`RegisterSupervisor` adds request and response messages to the public closure.
479
+
Its assignment response carries initial runtime credentials but is not persisted
480
+
as a protobuf storage root. Warm-pool selection and synchronization extend the
481
+
internal compute-driver contract; neither changes the durable schema inventory.
482
+
473
483
`ReportEndpointStatus` is a sandbox-authenticated public gateway RPC. Its request, response, and `EndpointObservation` messages belong only to the public closure. `EndpointStatus` and `EndpointResult` also belong to the durable closure because `Sandbox.status.endpoint_statuses` persists them. The repeated status field uses a new wire tag; stored sandboxes without it decode with an empty endpoint list and retain their lifecycle fields. A fixed payload encoded with the earlier sandbox schema verifies that no database rewrite is required.
474
484
475
485
Allow and deny append requests carry `L7RuleTarget` to declare the rule, endpoint, and complete affected scope. The removed `host` and `port` fields remain reserved by number and name, and requests without a target are rejected. These mutation requests are not persisted formats.
@@ -621,6 +631,20 @@ revisions commit in one database transaction. SQLite serializes this operation
621
631
with an immediate transaction, while Postgres locks the sandbox row. A failed
622
632
resource-version check or revision insert rolls back the entire operation.
623
633
634
+
Warm allocation intent and its exclusive target reservation commit in one
635
+
transaction. The `allocation_claims` table keys ownership by configured driver,
636
+
namespace, and physical UID; the owner is a sandbox provisioning attempt and
637
+
runtime generation. A uniqueness conflict rolls back the sandbox write and
638
+
allows immediate selection of another target. Reservations have no TTL and
639
+
survive ambiguous driver outcomes and gateway restart. Only fenced or reclaimed
640
+
allocations release ownership; deleting the owning sandbox cascades its claims.
641
+
The driver's resource CAS still arbitrates physical assignment and retirement.
642
+
Creates with attached providers hold the gateway-wide sandbox lock from provider
643
+
validation through the sandbox and reservation commit, including reservation
644
+
retries. They release it before submitting creation to the driver. Allocation
645
+
completion and recovery then acquire their own synchronization and lifecycle
646
+
locks.
647
+
624
648
SQLite is the default local store; Postgres is supported for deployments that
625
649
need an external database or multi-replica coordination. Both backends expose
626
650
the same `Store` API and the same logical schema. Backend differences stay
0 commit comments