fix(e2e): cross-platform Docker isolation for e2e-walkthrough #600

Merged
xiaomo merged 1 commits from fix/e2e-walkthrough-cross-platform into main 2026-06-02 11:02:06 +00:00
Owner

What

Fix e2e-walkthrough.yaml to work correctly on macOS (previously only tested on Linux).

Why

Three cross-platform bugs caused failures and host corruption:

  1. -v $HOME:$HOME let container bun install overwrite host bun binary (Linux ARM64 replaced macOS ARM64)
  2. Container could not reach host LLM endpoints (localhost ≠ host inside Docker on macOS)
  3. Hardcoded ~/repos/workflow path did not exist on macOS

Changes

  • Read-only mount: -v $(pwd):/workspace:ro + cp -r inside container
  • Container-local HOME: -e HOME=/root isolates bun/npm installs
  • Host network access: --add-host=host.docker.internal:host-gateway (Linux compat)
  • Config injection: docker cp host config + sed rewrite localhost → host.docker.internal
  • Path portability: $(pwd) and /root/workflow instead of hardcoded paths
  • Minor fixes: debate.yaml instead of solve-issue.yaml (no $SUSPEND dep); --status cancelled fix

Verification

Full 6-step walkthrough passes on macOS, host bun binary intact after run:

Step 1 [bootstrap]:           pass (127s)
Step 2 [config-and-registry]:  pass (49s)
Step 3 [thread-ops]:           pass (327s)
Step 4 [inspect]:              pass (32s)
Step 5 [cancel-and-fork]:      pass (49s)
Step 6 [cleanup]:              pass (20s)
## What Fix e2e-walkthrough.yaml to work correctly on macOS (previously only tested on Linux). ## Why Three cross-platform bugs caused failures and host corruption: 1. `-v $HOME:$HOME` let container bun install overwrite host bun binary (Linux ARM64 replaced macOS ARM64) 2. Container could not reach host LLM endpoints (localhost ≠ host inside Docker on macOS) 3. Hardcoded `~/repos/workflow` path did not exist on macOS ## Changes - **Read-only mount**: `-v $(pwd):/workspace:ro` + `cp -r` inside container - **Container-local HOME**: `-e HOME=/root` isolates bun/npm installs - **Host network access**: `--add-host=host.docker.internal:host-gateway` (Linux compat) - **Config injection**: `docker cp` host config + `sed` rewrite localhost → host.docker.internal - **Path portability**: `$(pwd)` and `/root/workflow` instead of hardcoded paths - **Minor fixes**: `debate.yaml` instead of `solve-issue.yaml` (no $SUSPEND dep); `--status cancelled` fix ## Verification Full 6-step walkthrough passes on macOS, host bun binary intact after run: ``` Step 1 [bootstrap]: pass (127s) Step 2 [config-and-registry]: pass (49s) Step 3 [thread-ops]: pass (327s) Step 4 [inspect]: pass (32s) Step 5 [cancel-and-fork]: pass (49s) Step 6 [cleanup]: pass (20s) ```
xingyue added 1 commit 2026-06-02 10:30:02 +00:00
fix(e2e): cross-platform Docker isolation for e2e-walkthrough
CI / check (pull_request) Failing after 1m35s
008701ef46
Problems on macOS:
- `-v $HOME:$HOME` let container's bun install overwrite host bun
  binary (Linux ARM64 replaced macOS ARM64)
- Container couldn't reach host LLM endpoints (localhost != host)
- Hardcoded `~/repos/workflow` path didn't exist on all machines

Fixes:
- Mount source read-only (`-v $(pwd):/workspace:ro`) + copy inside
- Use container-local HOME (/root) to isolate bun/npm installs
- Add `--add-host=host.docker.internal:host-gateway` for Linux compat
- `docker cp` host config + sed localhost→host.docker.internal
- Use `debate.yaml` instead of `solve-issue.yaml` (no $SUSPEND dep)
- Fix cancel test: `--status cancelled` not `--status completed`

Verified: full 6-step walkthrough passes on macOS, host bun intact.
xiaomo approved these changes 2026-06-02 11:01:58 +00:00
xiaomo left a comment
Owner

LGTM

三个跨平台问题修得干净:

  1. :ro mount + cp -r 隔离,防止 bun install 覆盖宿主 binary
  2. host.docker.internal 解决容器内访问宿主 LLM
  3. --status cancelled 修正 typo

debate.yaml 替代 solve-issue.yaml 避免 $SUSPEND 依赖也合理。

LGTM ✅ 三个跨平台问题修得干净: 1. `:ro` mount + `cp -r` 隔离,防止 bun install 覆盖宿主 binary 2. `host.docker.internal` 解决容器内访问宿主 LLM 3. `--status cancelled` 修正 typo `debate.yaml` 替代 `solve-issue.yaml` 避免 $SUSPEND 依赖也合理。
xiaomo merged commit 6802aecb2e into main 2026-06-02 11:02:06 +00:00
xiaomo deleted branch fix/e2e-walkthrough-cross-platform 2026-06-02 11:02:06 +00:00
Sign in to join this conversation.
No Reviewers
No Label
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: uncaged/workflow#600