Skip to content

WIP: Add Kubernetes sandbox runtime - #211

Draft
whatever wants to merge 1 commit into
mainfrom
feat/kubernetes-sandbox-type
Draft

WIP: Add Kubernetes sandbox runtime#211
whatever wants to merge 1 commit into
mainfrom
feat/kubernetes-sandbox-type

Conversation

@whatever

@whatever whatever commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add KubernetesSandboxBackend behind the existing provider-neutral sandbox contract
  • add a pod-backed KubernetesSandbox instance with exec, file transfer, resource policy, and cleanup
  • select it with CLEARWING_SANDBOX_BACKEND=kubernetes and a deployment-managed CLEARWING_SANDBOX_IMAGE
  • package the Kubernetes client as an optional dependency

Verification

  • uv run pytest tests/test_sandbox_backends.py tests/test_kubernetes_sandbox.py tests/test_sandbox_container.py tests/test_sandbox_writable_workspace.py -q (65 passed)
  • uv run ruff check clearwing/sandbox/backend.py clearwing/sandbox/__init__.py clearwing/sandbox/kubernetes.py tests/test_kubernetes_sandbox.py
  • uv run mypy --follow-imports=skip clearwing/sandbox/kubernetes.py

WIP notes

This intentionally uses a pre-built, deployment-managed sandbox image. On-cluster image building and live-cluster integration coverage are follow-up decisions before marking ready.

Conflict scan

PR #200 already merged the sandbox backend contracts used here. No active PR currently models a competing Kubernetes sandbox backend or lifecycle.

@whatever
whatever force-pushed the feat/kubernetes-sandbox-type branch from 72295db to 9325b44 Compare September 3, 2026 21:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant