feat(sandbox): add vi, jq, and dos2unix to base images#3091
Conversation
Fixes #2999 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
📝 WalkthroughWalkthroughThree essential Linux utilities—dos2unix, jq, and vim-tiny—are pinned to specific Debian versions and added to the apt-get install block in two base Dockerfiles, addressing missing sandbox tools. ChangesBase Image Utilities
Estimated Code Review Effort🎯 1 (Trivial) | ⏱️ ~3 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)
Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (2)
Dockerfile.base (1)
55-71: Run container-level E2E jobs for this base-image layer change.Since this modifies sandbox base image contents, please run the recommended selective jobs before merge:
cloud-e2e,sandbox-survival-e2e,hermes-e2e,rebuild-openclaw-e2e.As per coding guidelines, "
Dockerfile.base: This file affects the sandbox container image. Layer ordering, permissions, and baked config changes are only testable with a real container build."🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@Dockerfile.base` around lines 55 - 71, This change modifies the sandbox base image RUN apt-get layer (the RUN apt-get update && apt-get install -y ... block in Dockerfile.base) so before merging, trigger the prescribed container-level E2E jobs — run cloud-e2e, sandbox-survival-e2e, hermes-e2e, and rebuild-openclaw-e2e — to validate layer ordering, permissions, and baked config in a real container build; if any test fails, iterate on the package list or layer ordering in the RUN apt-get block and re-run the same E2E jobs until all pass.agents/hermes/Dockerfile.base (1)
32-49: Run Hermes-focused E2E workflows for this base-image update.For confidence on onboarding/probe/routing paths, run:
hermes-e2e,hermes-discord-e2e,rebuild-hermes-e2e,rebuild-hermes-stale-base-e2e.As per coding guidelines, "
agents/hermes/**: This directory contains the Hermes agent. Changes affect multi-agent onboarding, health probes, and inference routing."🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@agents/hermes/Dockerfile.base` around lines 32 - 49, Run Hermes-focused end-to-end tests to validate the base-image package changes in agents/hermes/Dockerfile.base: execute the hermes-e2e, hermes-discord-e2e, rebuild-hermes-e2e, and rebuild-hermes-stale-base-e2e workflows against the updated RUN apt-get ... block to confirm onboarding, probe, and routing paths still work for the Hermes agent after the package/version updates.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@agents/hermes/Dockerfile.base`:
- Around line 32-49: Run Hermes-focused end-to-end tests to validate the
base-image package changes in agents/hermes/Dockerfile.base: execute the
hermes-e2e, hermes-discord-e2e, rebuild-hermes-e2e, and
rebuild-hermes-stale-base-e2e workflows against the updated RUN apt-get ...
block to confirm onboarding, probe, and routing paths still work for the Hermes
agent after the package/version updates.
In `@Dockerfile.base`:
- Around line 55-71: This change modifies the sandbox base image RUN apt-get
layer (the RUN apt-get update && apt-get install -y ... block in
Dockerfile.base) so before merging, trigger the prescribed container-level E2E
jobs — run cloud-e2e, sandbox-survival-e2e, hermes-e2e, and rebuild-openclaw-e2e
— to validate layer ordering, permissions, and baked config in a real container
build; if any test fails, iterate on the package list or layer ordering in the
RUN apt-get block and re-run the same E2E jobs until all pass.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Enterprise
Run ID: 22aca7fc-412e-4921-a327-6780b1700596
📒 Files selected for processing (2)
Dockerfile.baseagents/hermes/Dockerfile.base
## Summary - Bump the docs release metadata to `0.0.37`. - Document release-prep updates for messaging policy presets, sandbox runtime utilities, and the GPU CDI troubleshooting path. - Refresh generated `nemoclaw-user-*` skills from the updated docs. ## Source summary - #3159 -> `docs/reference/troubleshooting.md`: Documents the GPU CDI preflight warning and remediation for `nvidia.com/gpu=all` gateway start failures. - #2415 -> `docs/reference/network-policies.md`, `docs/manage-sandboxes/messaging-channels.md`, `docs/network-policy/customize-network-policy.md`: Clarifies that Telegram, Discord, and Slack egress comes from opt-in messaging presets, not the baseline policy. - #3091 -> `docs/deployment/sandbox-hardening.md`, `docs/network-policy/customize-network-policy.md`: Documents the retained sandbox utilities `vi`, `jq`, and `dos2unix` while keeping host-side policy files as the durable source of truth. ## Test plan - `python3 scripts/docs-to-skills.py docs/ .agents/skills/ --prefix nemoclaw-user` - `make docs` - `npm run build:cli` - `npm run typecheck:cli` - Commit and pre-push hooks: markdownlint, docs-to-skills verification, gitleaks, commitlint, CLI typecheck ## Skipped - #3193 and #3191 matched `docs/.docs-skip` entries for experimental shields/config paths. - #3200 and #3183 were test-only fixes. - #3189 and #3163 were internal documentation/refactor changes with no public docs impact. Made with [Cursor](https://cursor.com) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Documentation** * Clarified which utilities remain in the sandbox runtime for lightweight inspection and cleanup * Noted that messaging endpoints (Discord, Slack, Telegram) are not in the baseline policy and that channel presets are applied during onboarding * Added GPU passthrough troubleshooting for gateway startup * Updated release/version bump and release-prep workflow guidance, including Discord preset description updates <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Cursor <cursoragent@cursor.com>
Summary
Adds three essential Linux tools —
vi(vim-tiny),jq, anddos2unix— to both the OpenClaw and Hermes sandbox base images. These tools are commonly expected in any interactive shell environment and are frequently needed for ad-hoc editing and data wrangling inside a running sandbox.Related Issue
Fixes #2999
Changes
Dockerfile.base: adddos2unix=7.4.3-1,jq=1.6-2.1+deb12u1,vim-tiny=2:9.0.1378-2+deb12u2(Debian bookworm, exact versions)agents/hermes/Dockerfile.base: same three packages added aftersocatType of Change
Verification
npx prek run --all-filespassesnpm testpassesmake docsbuilds without warnings (doc changes only)Signed-off-by: jason-ma-nv jama@nvidia.com
Summary by CodeRabbit