Skip to content

Isolate Docker workspaces by default - #5170

Open
kexinoh wants to merge 2 commits into
OpenHands:mainfrom
kexinoh:fix/docker-workspace-isolation
Open

kexinoh wants to merge 2 commits into
OpenHands:mainfrom
kexinoh:fix/docker-workspace-isolation

Conversation

@kexinoh

@kexinoh kexinoh commented Sep 18, 2026

Copy link
Copy Markdown

Summary

  • Create a private bridge network for each Docker workspace by default.
  • Add an offline mode that disables bridge IP masquerading while keeping the loopback control port available.
  • Bind published control ports to loopback and generate a per-workspace session key.
  • Clean up containers and networks reliably on startup and shutdown failures.

Validation

  • uv run ruff check openhands-workspace/openhands/workspace/docker/workspace.py tests/workspace/test_docker_workspace.py
  • uv run pytest tests/workspace/test_docker_workspace.py -q (18 passed)

kexinoh and others added 2 commits September 18, 2026 18:14
Co-authored-by: openhands <openhands@all-hands.dev>
Co-authored-by: openhands <openhands@all-hands.dev>
@all-hands-bot

Copy link
Copy Markdown
Collaborator

👋 This PR needs a couple of things fixed before OpenHands can review it:

  • the PR description's HUMAN: section needs at least 20 characters describing what you tested, not just the template placeholder

Push an update once this is addressed and this check re-runs automatically.

This is an automated check - no AI was used to generate this comment.

@kexinoh
kexinoh force-pushed the fix/docker-workspace-isolation branch from c9fea8d to 5d33e79 Compare September 21, 2026 02:04
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.

2 participants