Skip to content

feat: add dockerShmSize option to raise Docker's /dev/shm limit - #81

Merged
frostebite merged 2 commits into
mainfrom
feat/docker-shm-size
Aug 14, 2026
Merged

feat: add dockerShmSize option to raise Docker's /dev/shm limit#81
frostebite merged 2 commits into
mainfrom
feat/docker-shm-size

Conversation

@frostebite

Copy link
Copy Markdown
Member

Brings the fix from unity-test-runner#308 (mob-sakai) into the CLI, since build/test logic now lives here rather than in the action repos directly.

What

Unity 6.6 beta / 6.7 alpha editors have been reported to fail against Docker's 64MB default /dev/shm:

Error: Requested 1073741824 bytes, but only 67108864 bytes available
Error: Insufficient shared memory available - if using Docker, please run the container with --shm-size=1025M

Adds a dockerShmSize option (empty/unset by default — matches Docker's own default and doesn't change behavior for editors that don't need it), following the exact pattern of the existing dockerCpuLimit/dockerMemoryLimit options. Wired into both the Linux and Windows docker run command builders in Docker.

Why not port the original PR's unconditional --shm-size=1025m

The original fix hardcoded --shm-size=1025m on every run. Making it an opt-in flag (--docker-shm-size 1025m) instead avoids silently changing resource allocation for every user on every Unity version, while still giving people hitting this specific error (older/beta editors) a documented way to fix it — same shape as the other Docker resource options already here.

Testing

  • New tests in docker.test.ts: --shm-size appears on both Linux and Windows commands when dockerShmSize is set, and is omitted entirely when unset.
  • bun run test — 148 pass, 3 skip, 0 fail.

🤖 Generated with Claude Code

@coderabbitai

coderabbitai Bot commented Aug 14, 2026

Copy link
Copy Markdown

Important

Review available on request

  • 🔍 Trigger review

Reviews should be triggered manually for repositories with fewer than 10 stars. Select Trigger review above or comment @coderabbitai review to review the latest changes. For a full review, comment @coderabbitai full review.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: ce2f73bc-8840-49b0-b038-fa476c4080d7


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

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