Repository navigation
fix(docker): install a CA bundle so the Sentry CLI can verify TLS (#16) - #21
Conversation
The deploy of #20 failed, which is the guard working: the plugin got far enough to actually call the Sentry API for the first time since April 2024, and sentry-cli releases new 6e751d2… [60] SSL peer certificate or SSH remote key was not OK (unable to get local issuer certificate) `node:22.23.3-bookworm-slim` ships no CA bundle at all — no `/etc/ssl/certs/ca-certificates.crt`, no `ca-certificates` package. Node is unaffected because it bundles its own roots, which is exactly why `npm install` succeeded and nothing else looked wrong. The native `sentry-cli` the bundler plugin shells out to is a different matter and reads the system store. Build stage only, so the runtime image stays slim.
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (2)
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe Docker build stage now installs ChangesDocker CA certificates
Priority: ➖ Normal Estimated code review effort: 2 (Simple) | ~5 minutes Change: Bug fix Merge Risk: ⚪ Minimal · up to The production build installs system CA certificates before running Sentry release and source-map operations. No actionable merge-blocking risk remains. Security Architecture ReviewSecurity architecture risk: 🔵 Low · up to This is a narrowly scoped build-time trust-store change that preserves TLS verification and does not extend runtime privileges. No security regression was demonstrated, but recovery after partially completed Sentry operations remains unverified. Retained concerns Security review detailsSecurity Blast Radius
Trust Boundaries and Controls
Resilience and Maintainability Implications
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
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. Comment |
Follow-up to #20, which is correct but does not deploy.
Merging it turned the previously unreachable Sentry API call into a reachable one, and it failed:
node:22.23.3-bookworm-slimships no CA bundle at all:Node is unaffected because it bundles its own root store, which is why
npm installworked and nothing else in the build looked wrong. The nativesentry-clithat@sentry/vite-pluginshells out to is a Rust binary that reads the system store instead, so it is the only thing in this image that cannot make an HTTPS request.Adds
ca-certificatesto the build stage only — the runtime image stays slim — plus a test pinning it, since the failure is invisible until a real upload is attempted and there is no local harness for a remote build.Worth noting how this surfaced: because #20 sets
errorHandlerto rethrow, the deploy failed. Before that the same TLS problem would have been logged and swallowed, the maps deleted in the plugin'sfinally, and the build green — the original #16 symptom, one layer further down.Verified:
npm run validateclean · 20 tests intests/sentry-release.test.ts.Summary by CodeRabbit