fix: pass OPENCODE_CONFIG_EXTRA and CODEX_CONFIG_EXTRA to sandbox containers (closes #77)#87
fix: pass OPENCODE_CONFIG_EXTRA and CODEX_CONFIG_EXTRA to sandbox containers (closes #77)#87
Conversation
…through allowlists (closes #77) - Append CODEX_CONFIG_EXTRA to CODEX_PASSTHROUGH_ENVS in docker_manager.py - Append OPENCODE_CONFIG_EXTRA to OPENCODE_PASSTHROUGH_ENVS in docker_manager.py - Extend _clear_phase6_auth_env() to pop both new keys so reload fixture is clean - Add both stub values to overrides dict in test_passthrough_isolation - Update all 3 parametrize rows: claude forbids both; codex expects CODEX_CONFIG_EXTRA and forbids OPENCODE_CONFIG_EXTRA; opencode expects OPENCODE_CONFIG_EXTRA and forbids CODEX_CONFIG_EXTRA
|
Warning Rate limit exceeded
To keep reviews running without waiting, you can enable usage-based add-on for your organization. This allows additional reviews beyond the hourly cap. Account admins can enable it under billing. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughThe PR extends Docker environment variable passthrough allowlists in the orchestrator to include ChangesEnvironment Variable Allowlist Expansion
Estimated Code Review Effort🎯 2 (Simple) | ⏱️ ~10 minutes Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Tip 💬 Introducing Slack Agent: Turn conversations into code.Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.
Built for teams:
One agent for your entire SDLC. Right inside Slack. 👉 Get your free trial and get 200 agent minutes per Slack user (a $50 value). 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. Review rate limit: 0/1 reviews remaining, refill in 56 minutes and 39 seconds.Comment |
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
… the per-CLI passthrough allowlists Both entries reference the existing recipes in docs/cli-config-templates.md and explain the orchestrator → sandbox boundary they cross, so a future reader does not have to chase the issue history to understand the intent.
Summary
OPENCODE_CONFIG_EXTRAtoOPENCODE_PASSTHROUGH_ENVSandCODEX_CONFIG_EXTRAtoCODEX_PASSTHROUGH_ENVSincomputer-use-server/docker_manager.py, so the orchestrator passes operator-supplied config overrides into spawned sandbox containers.tests/orchestrator/test_passthrough_isolation.pyto lock in the new allowlist entries and the per-CLI isolation contract (Pitfall 1): claude forbids both, codex expects onlyCODEX_CONFIG_EXTRA, opencode expects onlyOPENCODE_CONFIG_EXTRA.Why
Per issue #77: the Dockerfile entrypoint (line 428–449) already consumes
OPENCODE_CONFIG_EXTRAto render/tmp/opencode.jsonfrom operator-supplied JSON, anddocs/cli-config-templates.mddocuments this as the supported override surface for proxy-only routing (LiteLLM, OpenLLM, etc.). But the var was missing from the orchestrator's per-CLI passthrough allowlist, so it never crossed the orchestrator → sandbox boundary — operators could not route opencode through a self-hosted gateway without a local source patch. Same gap applied toCODEX_CONFIG_EXTRA.This PR is a 2-line allowlist addition; no version bump, no docs changes (docs were already correct — this makes the code match).
Test plan
pytest tests/orchestrator/test_passthrough_isolation.py -v— 3 parametrize cases passpytest tests/orchestrator/test_docker_manager.py -v— 10 module-load tests, no regression--platform linux/amd64, setOPENCODE_CONFIG_EXTRAin.env, recreatecomputer-use-server, confirmdocker exec <sandbox> printenv | grep OPENCODE_CONFIG_EXTRAis non-empty and/tmp/opencode.jsonreflects the operator override.Closes #77.
Summary by CodeRabbit
Chores
CODEX_CONFIG_EXTRAandOPENCODE_CONFIG_EXTRAcan now be passed through to their respective runtimes.Tests