Skip to content

fix: let local sandboxes work on Docker Desktop - #417

Merged
HomelessDinosaur merged 1 commit into
mainfrom
docker-desktop-sandboxes
Oct 16, 2026
Merged

HomelessDinosaur merged 1 commit into
mainfrom
docker-desktop-sandboxes

Conversation

@davemooreuws

@davemooreuws davemooreuws commented Oct 15, 2026 •

Copy link
Copy Markdown
Member

On Docker Desktop the host can't reach Docker's bridge address, 172.17.0.1, which OpenSandbox put in every sandbox address it returned, so the API never reached a local sandbox.

OpenSandbox 1.1.0 takes two hosts, so compose.yml now sets each to one that works everywhere:

  • [server].eip = "127.0.0.1" is the host in the addresses returned to the API. Sandbox ports are published on 0.0.0.0 (hard-coded as DOCKER_PUBLISH_HOST), so they answer on loopback, and Docker Desktop forwards them to the host's loopback.
  • [docker].host_ip = "host.docker.internal" is how the OpenSandbox container itself reaches them, for its proxy and egress readiness check. The service's extra_hosts: host-gateway entry resolves it on Docker Engine and Docker Desktop.

publish_host is gone: OpenSandbox's DockerConfig has no such field and Pydantic ignores unknown keys, so it never did anything. With no setting left to choose, OPENSANDBOX_HOST_IP is gone too.

The OpenSandbox tests (sandboxes.test.ts, tools/sandbox.test.ts) pass on Docker Desktop for Windows and on Docker Engine on Ubuntu 24.04 (a temporary Actions run, removed). Docker Desktop for Mac should behave like Windows but hasn't been run.

An existing OpenSandbox needs docker compose --profile sandboxes up -d --force-recreate opensandbox: Compose doesn't recreate it when only the inline config changes.

Closes SUGA-2002

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Oct 15, 2026 •

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Updated (UTC)
✅ Deployment successful!
View logs
sugabots-website 366bc8f Oct 15 2026, 06:28 AM

@davemooreuws

Copy link
Copy Markdown
Member Author

@jyecusch / @HomelessDinosaur could you test this on Mac?

@HomelessDinosaur

Copy link
Copy Markdown
Member

Worked for me

@HomelessDinosaur
HomelessDinosaur merged commit 87edd7f into main Oct 16, 2026
12 of 13 checks passed
@HomelessDinosaur
HomelessDinosaur deleted the docker-desktop-sandboxes branch October 16, 2026 05:58
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