Repository navigation
Conversation
Signed-off-by: Ralph Bean <rbean@redhat.com>
PR Summary by QodoSupport read-only OCI image mounts in harness sandboxes
AI Description
Diagram
High-Level Assessment
Files changed (36)
|
|
🤖 Finished Review · ✅ Success · Started 9:59 PM UTC · Completed 10:12 PM UTC Commit: Runtime: pi · Model: sonnet → claude-sonnet-5-5 · Effort: high · Cost: $3.16 |
Site previewPreview: https://fbca3908-site.fullsend-ai.workers.dev Commit: |
Code Review by Qodo
1.
|
| in `filesystem_policy.read_only`. The OpenShell Podman gateway must enable | ||
| `allow_driver_config` and disable resource admission. The `fullsend-sandbox` |
There was a problem hiding this comment.
5. User guide includes operator-only setup 📜 Skill insight ⌂ Architecture
The new image_mounts subsection in the bring-your-own-agent guide tells harness authors to configure the OpenShell Podman gateway with allow_driver_config and disabled resource admission, which is platform-operator material placed in docs/guides/user/. A reader cannot tell which parts of the section apply to them, so the guide now addresses two audiences.
Agent Prompt
## Issue description
The `image_mounts` subsection in `docs/guides/user/bring-your-own-agent.md` tells harness authors to configure the OpenShell Podman gateway (`allow_driver_config`, resource admission). Compliance rule 1062077 requires each guide to address a single audience.
## Fix Focus Areas
- docs/guides/user/bring-your-own-agent.md[533-544]
## Recommended Fix
Keep the harness and policy steps (`image_mounts` entry, `/opt/fullsend` in `read_only`, choosing the tools image) in the user guide. Move the gateway configuration requirement to the operator or infrastructure guide, and link to it from this section in one sentence.
ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools
|
Risk Assessment: elevated (3/5) DetailsScore remains elevated at 3 despite PR expansion from 36 to 63 files because modifications to protected paths, CI workflows, and high-churn runtime components are balanced by solid test coverage (38%), an established author, and no dependency changes. Previous runRisk Assessment: elevated (3/5) DetailsLarge multi-file feature touching protected paths and CI workflows across high-churn runtime components, balanced by an accepted ADR design and solid test coverage. Previous run (2)Risk Assessment: elevated (3/5) DetailsLarge feature adding OCI image mounts across 36 files with CI workflow and protected path modifications, moderate test coverage, and high churn on core runner components, with no linked issue. |
ReviewFindingsM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SI6ZmFsc2UsImRpbWVuc2lvbiI6InN0eWxlLWNvbnZlbnRpb25zIn0seyJzZXZlcml0eSI6ImxvdyIsImNhdGVnb3J5IjoiYmFja3dhcmQtaW5jb21wYXRpYmxlIiwiZmlsZSI6ImludGVybmFsL3NhbmRib3gvc2FuZGJveC5nbyIsImlkIjoiZl8zNTU2YWFhYmM3MTQzMjA2IiwibGluZSI6MTQzOSwiYWN0aW9uYWJsZSI6ZmFsc2UsImRpbWVuc2lvbiI6ImNyb3NzLXJlcG8tY29udHJhY3RzIn1dfQ== --> ReviewFindingsHigh
Medium
Low
Labels: PR also changes documentation and the sandbox-images CI workflow, alongside the existing sandbox and harness component labels. Next steps:
Previous run (2)ReviewReason: tool-failure This PR was NOT reviewed. Do not count this as an approval. Previous run (3)<!-- fullsend:review-findings-v2:eyJ2ZXJzaW9uIjoyLCJhY3Rpb24iOiJyZXF1ZXN0LWNoYW5nZXMiLCJmaW5kaW5ncyI6W3sic2V2ZXJpdHkiOiJoaWdoIiwiY2F0ZWdvcnkiOiJsb2dpYy1lcnJvciIsImZpbGUiOiJpbnRlcm5hbC9ydW50aW1lL2Vudl9kYXRhLmdvIiwiaWQiOiJmXzBkNmQ2YjRhMWI0NDAyM2MiLCJsaW5lIjoxMzgsImFjdGlvbmFibGUiOnRydWUsImRpbWVuc2lvbiI6ImNvcnJlY3RuZXNzIn0seyJzZXZlcml0eSI6ImhpZ2giLCJjYXRlZ29yeSI6ImJhY2t3YXJkLWluY29tcGF0aWJsZSIsImZpbGUiOiJpbnRlcm5hbC9zYW5kYm94L3NhbmRib3guZ28iLCJpZCI6ImZfZTlkN2Y3NTVmODVkYjkzNyIsImxpbmUiOjY4LCJhY3Rpb25hYmxlIjp0cnVlLCJkaW1lbnNpb24iOiJjcm9zcy1yZXBvLWNvbnRyYWN0cyJ9LHsic2V2ZXJpdHkiOiJtZWRpdW0iLCJjYXRlZ29yeSI6InBhdHRlcm4taW5jb25zaXN0ZW5jeSIsImZpbGUiOiJpb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W5zaW9uIjoic3R5bGUtY29udmVudGlvbnMifSx7InNldmVyaXR5IjoibG93IiwiY2F0ZWdvcnkiOiJicmVha2luZy1jb25maWciLCJmaWxlIjoiaW50ZXJuYWwvYWdlbnRuZXcvdGVtcGxhdGVzL3BvbGljaWVzL2Jhc2UueWFtbCIsImlkIjoiZl85YmI4ZDU2OWNiZTAzNGVhIiwibGluZSI6MTYsImFjdGlvbmFibGUiOnRydWUsImRpbWVuc2lvbiI6ImNyb3NzLXJlcG8tY29udHJhY3RzIn0seyJzZXZlcml0eSI6ImxvdyIsImNhdGVnb3J5IjoiYnJlYWtpbmctc2NoZW1hIiwiZmlsZSI6ImludGVybmFsL2hhcm5lc3MvaW1hZ2VfbW91bnQuZ28iLCJpZCI6ImZfZTUyNzlkNmNkMThjMjJjMiIsImxpbmUiOjI4LCJhY3Rpb25hYmxlIjpmYWxzZSwiZGltZW5zaW9uIjoiY3Jvc3MtcmVwby1jb250cmFjdHMifV19 --> ReviewFindingsHigh
Medium
Low
Labels: PR changes harness composition/validation and the sandbox image/runtime layout. Next steps:
|
Signed-off-by: Ralph Bean <rbean@redhat.com>
|
🤖 Review · ❌ Terminated · Started 12:42 AM UTC · Ended 1:06 AM UTC Commit: |
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
|
🤖 Finished Review · ❌ Failure (post-script /home/runner/work/fullsend/fullsend/.fullsend/.fullsend-cache/resources/sha256/401c0ce973a89277564d7ecee02103ae504d2405692f0cf9618bcf9c48db6ba1/scripts/post-review.sh failed: exit status 1) · Started 12:42 AM UTC · Completed 1:05 AM UTC Commit: Runtime: pi · Model: sonnet → claude-sonnet-5-5 · Effort: high · Cost: $0.67 |
Signed-off-by: Ralph Bean <rbean@redhat.com>
|
🤖 Finished Review · ✅ Success · Started 12:14 PM UTC · Completed 12:45 PM UTC Commit: Runtime: pi · Model: sonnet → claude-sonnet-5-5 · Effort: high · Cost: $4.33 |
Signed-off-by: Ralph Bean <rbean@redhat.com>
Signed-off-by: Ralph Bean <rbean@redhat.com>
Signed-off-by: Ralph Bean <rbean@redhat.com>
Signed-off-by: Ralph Bean <rbean@redhat.com>
Signed-off-by: Ralph Bean <rbean@redhat.com>
Signed-off-by: Ralph Bean <rbean@redhat.com>
|
🤖 Finished Review · ✅ Success · Started 8:46 PM UTC · Completed 9:06 PM UTC Commit: Runtime: pi · Model: sonnet → claude-sonnet-5-5 · Effort: high · Cost: $3.76 |
There was a problem hiding this comment.
Note: The following review comments could not be posted on the diff (GitHub returned 422) and are included here instead:
docs/reference/harness-reference.md(file-level): Line 573 ·
[low] incomplete-doc
The 'Field merge rules (for base and overlays)' table has no image_mounts row, although docs/guides/user/bring-your-own-agent.md sends readers to that table for image_mounts merge behavior. The semantics are documented in the field description earlier on the page.
Suggested fix: Add an image_mounts row (concatenated; child overrides by dest, keeping first position), or point the guide's link at the field description.
| @@ -472,6 +478,8 @@ RUN apt-get update \ | |||
| && pip install --no-cache-dir --break-system-packages \ | |||
There was a problem hiding this comment.
[medium] logic-error
pre-commit and gitlint are installed with system pip into default site-packages; their launchers use an absolute /usr/bin/python3 shebang. When the tools image is mounted at /opt/fullsend, its launchers are found first (SandboxFullsendToolPath is prepended to PATH) and run under the development image's Python, whose sys.path lacks the mounted dist-packages, failing with ModuleNotFoundError. jsonschema alone gets a dedicated --target path handled by the mounted interpreter.
Suggested fix: Give pre-commit and gitlint mount-aware launchers (or install them under a dedicated target with wrappers, as done for jsonschema) that call the mounted interpreter with the mounted library paths. Add a smoke test that runs both tools against a development image without them installed.
| filesystem_policy: | ||
| include_workdir: true | ||
| read_only: [/usr, /lib, /proc, /dev/urandom, /app, /etc, /var/log] | ||
| read_only: [/usr, /lib, /proc, /dev/urandom, /app, /etc, /var/log, /opt/fullsend] |
There was a problem hiding this comment.
[medium] breaking-config
/opt/fullsend was added to filesystem_policy.read_only only in the scaffold template. Policies already generated from the template, and custom policies, do not list it, so the mounted tool tree may not be readable under those policies.
Suggested fix: Add a migration note for repositories with existing or custom filesystem policies (add /opt/fullsend to read_only) and confirm custom policies behave as intended without it.
| @@ -127,8 +138,13 @@ const envDataWritableAncestor = `while :; do if test -w "$p" || test -O "$p"; th | |||
| // the launch runs as the owner of / (root), nothing could be protected, so | |||
| // only relative and empty entries and missing directories are left out. | |||
There was a problem hiding this comment.
[medium] breaking-config
The runner's trusted PATH now always puts /opt/fullsend/usr/local/bin:/opt/fullsend/usr/bin ahead of the ambient PATH (ambient PATH retained after them; the default image links these to /usr). Harnesses or images that depend on the previous PATH ordering may resolve tools differently.
| // ImageMount describes an OCI image mounted read-only into the sandbox. | ||
| // Image is an OCI image reference; Dest is the absolute mount point in the | ||
| // sandbox. The mounted image's OCI environment and entrypoint are not applied. | ||
| type ImageMount struct { |
There was a problem hiding this comment.
[low] missing-authorization
The PR does not close a tracking issue. It cites #5680 and #491 as related only; both are open and cover the same use case. The PR is a draft stacked on the docs/adr-0173-compose-images branch.
Suggested fix: State which issue authorizes this slice of work, or open a narrowly scoped tracking issue before the PR leaves draft.
| if err != nil { | ||
| return fmt.Errorf("encoding Podman image mounts: %w", err) | ||
| } | ||
| args = append(args, "--driver-config-json", string(config)) |
There was a problem hiding this comment.
[low] misplaced-abstraction
createOnce builds the Podman-specific podmanDriverConfig JSON and passes it through --driver-config-json inside the general sandbox creation lifecycle.
Suggested fix: Optionally move the backend-specific driver payload construction into a small builder so adding other backends does not touch createOnce.
|
|
||
| // sandboxFullsendToolPathCommand runs a fixed runner command with the | ||
| // mounted Fullsend tool image ahead of the sandbox's ambient PATH. | ||
| func sandboxFullsendToolPathCommand(command string) string { |
There was a problem hiding this comment.
[low] code-organization
sandboxFullsendToolPathCommand and sandboxFullsendToolPathCommandAt sit between EnvDataControlLines and its implementation envDataControlLines, splitting the pair.
Suggested fix: Move the helpers below envDataControlLines or next to the other sandbox command helpers.
| return CreateWithRetry(name, providers, image, policy, DefaultMaxCreateAttempts, 0, false, imageMounts...) | ||
| } | ||
|
|
||
| // ImageMount is an OCI image mounted read-only into a Podman-backed sandbox. |
There was a problem hiding this comment.
[low] code-organization
The ImageMount type is declared between Create and CreateWithRetry, separating Create from the function it delegates to.
| // piProviderExtensionPin prefers the relocated extension path and falls | ||
| // back to the path in the currently published sandbox image. The selected | ||
| // path is read-only before the agent-writable .env is processed. | ||
| func piProviderExtensionPin(variable, primary, legacy string) string { |
There was a problem hiding this comment.
[low] pattern-inconsistency
piProviderExtensionPin returns an unbraced if...fi fragment joined into an && chain, whereas some other pin helpers use a { ...; } brace group. Cosmetic only.
Repositories can use their development image as the sandbox base while Fullsend's tools remain available from a separate image mounted at
/opt/fullsend.image_mountsto harness composition and validation, merging entries by destination./opt/fullsend, with a Node startup check before repository setup.Related: #5680 tracks custom code-agent images; #491 tracks broader per-repository toolchain discovery. This covers the image-composition path, not enrollment-time detection or devcontainer sidecars.
Validation:
make lintpassed;git diff --checkpassed after rebasing on currentmain.