Repository navigation
fix(scanner): pin ramparts builder to rust:1-slim-bookworm (MCP-2395) - #665
Merged
Merged
Conversation
The unpinned rust:1-slim builder tag now resolves to Debian trixie (glibc 2.41) while the runtime stage stays on debian:bookworm-slim (glibc 2.36). The binary compiled on trixie links GLIBC_2.39 symbols that bookworm cannot satisfy, causing every ramparts scan to fail with: ramparts: /lib/aarch64-linux-gnu/libc.so.6: version GLIBC_2.39 not found Fix: pin the builder to rust:1-slim-bookworm so both build and runtime stages share glibc 2.36. Verified: docker build succeeds; `ramparts --version` exits 0 on the resulting image (no GLIBC error). Noted separately that the ramparts v0.8.x CLI has switched from file-based to URL-based scanning (entrypoint CLI compat tracked as follow-up issue). Co-Authored-By: Paperclip <[email protected]>
Deploying mcpproxy-docs with
|
| Latest commit: |
bb6e93d
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://21a2b565.mcpproxy-docs.pages.dev |
| Branch Preview URL: | https://fix-ramparts-glibc-bookworm.mcpproxy-docs.pages.dev |
|
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Contributor
📦 Build ArtifactsWorkflow Run: View Run Available Artifacts
How to DownloadOption 1: GitHub Web UI (easiest)
Option 2: GitHub CLI gh run download 27501643115 --repo smart-mcp-proxy/mcpproxy-go
|
The rust:1-slim-bookworm pin invalidated the buildx cache, forcing a cold cargo build of ramparts. Combined with the QEMU-emulated linux/arm64 leg (~5-10x slower), the cold build exceeds the runner budget and the job is cancelled mid-compile (last live line: Compiling want v0.3.1). Build ramparts for linux/amd64 only via a per-scanner matrix platforms override; the other (Python) scanners keep multi-arch. Co-Authored-By: Paperclip <[email protected]>
There was a problem hiding this comment.
Claude review ACCEPT — build-unblock: ramparts restricted to linux/amd64 (QEMU arm64 cold-compile blew runner budget); GLIBC bookworm pin preserved; CI-config-only change, scanner code unchanged. Tradeoff: ramparts image amd64-only (emulated on arm64 hosts) — acceptable given ramparts also needs a separate v0.8.x URL-scanning follow-up.
Dumbris
enabled auto-merge (squash)
June 14, 2026 16:22
Dumbris
added a commit
that referenced
this pull request
Jun 14, 2026
…ay shim (#670) Ramparts v0.8.x dropped file/directory scanning: `ramparts scan <target>` now requires a live MCP endpoint (URL or `stdio:`), and `scan`'s --format no longer accepts `sarif` nor a `--output` flag. The container's entrypoint still ran the stale `--format sarif --output FILE /scan/source`, so every scan failed even after the image was unblocked (MCP-2395/#665). Bridge the source-tree model to the new endpoint model without ever executing the untrusted upstream (preserves the no-exec invariant, MCP-2206/#658): - mcp-replay.py: a static MCP stdio server that replays the tool definitions MCPProxy already exports into /scan/source/tools.json (the same file the Cisco scanner consumes). entrypoint runs `ramparts scan stdio:python3:.../mcp-replay.py --format json`. Unit-tested against the rmcp handshake (initialize/tools-list/ resources/prompts/ping/notifications/unknown-method/missing-file). - Dockerfile: pin ramparts 0.8.2, ship its YARA `rules/`, `taxonomies/` and `config.yaml` (loaded relative to CWD — a binary-only image loads zero rules and finds nothing), and add a python3 runtime for the shim. - engine.go: the rampartsIssue parser was also stale — v0.8.x serializes `issue_type`/`severity`/`message`/`details` (+ per-kind subject), not the old `type`/`impact`, so security_issues parsed with empty rule IDs and wrong severities. Updated to the v0.8.x shape; the yara_results path was already compatible. Parser proven end-to-end with a faithful v0.8.2 `--format json` fixture. - registry: NetworkReq false (replay shim is local, YARA offline); refreshed description/comments. - docs: refresh the ramparts design + the now-fixed/amd64-only arm64 note. Full container E2E (built amd64 image vs a poisoned server) runs in CI/QA. Related MCP-2422
Dumbris
added a commit
that referenced
this pull request
Jun 22, 2026
ramparts (GLIBC_2.39): - Split CI matrix into per-arch native builds: ubuntu-latest for amd64, ubuntu-24.04-arm for arm64. Eliminates QEMU overhead that caused arm64 cargo-install to time out (MCP-2395), which left a stale arm64 manifest in GHCR linked against glibc 2.39 (trixie-era rust:1-slim). - Add merge-ramparts job: assembles the multi-arch :latest manifest from :latest-amd64 + :latest-arm64 using docker buildx imagetools create. - Dockerfile already has the bookworm pin (PR #665); no Dockerfile change needed. trivy-mcp (vuln-DB download timeout): - Add docker/scanners/trivy/Dockerfile: wraps ghcr.io/aquasecurity/trivy:latest and pre-caches the ~96 MiB vuln DB at build time via trivy image --download-db-only. TRIVY_CACHE_DIR=/trivy-cache baked in so runtime reads the same path without --cache-dir flags. - Update registry_bundled.go: DockerImage -> ghcr.io/smart-mcp-proxy/scanner-trivy, Timeout 300s -> 120s (no download needed for fs scans), update NetworkReq comment. - Add trivy to scanner-images.yml matrix (linux/amd64,linux/arm64). - Add weekly cron schedule (Monday 03:00 UTC) so the pre-cached DB stays current. Co-authored-by: Paperclip <[email protected]>
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.
Problem
The ramparts scanner image build uses a two-stage Dockerfile:
FROM rust:1-slim(unpinned)FROM debian:bookworm-slimThe unpinned
rust:1-slimtag recently moved to Debian trixie (glibc 2.41). The binary compiled there links symbols up toGLIBC_2.39, which bookworm's glibc 2.36 cannot satisfy. Every scan fails at startup with:Fix
Pin the builder to
rust:1-slim-bookwormso both stages share glibc 2.36.Verification
Tested locally on arm64:
rust:1-slim(old builder)rust:1-slim-bookworm(new builder)debian:bookworm-slim(runtime)Built the image with the fix —
ramparts --versionexits 0 cleanly (no GLIBC error).Known follow-up
During verification, discovered that
rampartsv0.8.x changed from a file-based scanner (directory path) to a URL-based scanner (ramparts scan <url>). The current entrypoint uses flags (--output,--format sarif, path argument) that no longer exist in v0.8.x. That entrypoint compatibility issue is tracked separately — it is a pre-existing design gap independent of this GLIBC crash.