feat(docker): parallel test runs across git worktrees without port conflicts (closes #676) - #775
Merged
s2x merged 5 commits intoAug 23, 2026
Conversation
added 5 commits
August 23, 2026 00:41
…OOT_VERSION, collision hints
… uid-safe auto-build, cache purge in publish mode
s2x
deleted the
feat/issue-676-run-the-dockerized-test-suite-in-paralle
branch
August 23, 2026 09:19
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Closes #676
Changes
bin/docker-test-worktree(new): runscomposer test/test:coverage/lintfor any git worktree in its own container of theworkerman-bundle-testimage. Each container has its own network namespace, so N parallel worktree suites cannot collide on ports 8888/9999/9991 — no-p, no code change. Container name (wmb-<worktree-basename>) and vendor volume (wmb-vendor-<worktree-basename>) are unique per checkout;var/stays in the worktree's own bind mount.--publishstarts ONLY the daemon with ephemeral host mappings (-p 127.0.0.1::8888|9999|9991), waits for all three ports to accept in-container, prints the mappings, and blocks until Ctrl-C/TERM (trap removes the container). Readiness failure is loud: prints adocker logs --tail 20excerpt and removes the container.tests/App/Kernel.php: the three listen addresses honourWMB_LISTEN_ADDR(default127.0.0.1— unset behavior is byte-identical), required for the publish flow so forwarded host connections reach the bridge interface.CONTRIBUTING.md: new "Parallel test runs across git worktrees" subsection (network-namespace guarantee, never-share-var/rule, per-worktree vendor volumes, publish/curl debug flow); the outdated ports note now lists all three ports and documentsWMB_LISTEN_ADDR.var/cache/dev/workerman/config.cache.php*at startup — a cache written inside the container holds/app-prefixed paths that crash host runs withmkdir(): Read-only file system, and vice versa a host-written cache trips the container-side ownership guard.Changelog
Two entries under
\[Unreleased\] → Added(helper + docs;WMB_LISTEN_ADDR).Proof of Work
docs/proof_of_work/0676-docker-worktree-parallel-tests/— 3 review roundsCode Review