Sign worker metrics certificates with CDI CA #4330
All Vouch review confidence checks passed
Residual risk 0.17 = Change Risk (0.42) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.42 · 337 lines diff across 4 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.348
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #4330"
general
weight: 0.35
davmarro
<!-- Thanks for sending a pull request! Here are some tips for you:
1. Follow the instructions for writing a release note from k8s: https://git.k8s.io/community/contributors/guide/release-notes.md
-->
What this PR does / why we need it:
Replace self-signed Prometheus metrics certificates for importer, clone-source, oVirt and OpenStack worker pods with certificates issued by the existing CDI upload server signer.
Inject the server certificate generator into the import, clone and forklift reconcilers and use the configured server certificate duration.
For oVirt and OpenStack populators, move certificate generation from the worker binaries to the controller, store the certificates in Secrets and mount them into the worker pods.
Reuse the existing certificate Secret and volume helpers, preserving Secret naming, labels, ownership and create-only behavior.
Centralize worker metrics certificate provisioning and move certificate configuration defaulting into controller/common, keeping the existing operator helper as a delegating wrapper and preserving defaulting behavior.
Unit tests cover certificate data, generator arguments, error propagation, preservation of existing Secrets, filesystem/block pod configuration, and certificate configuration defaulting.
Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)format, will close the issue(s) when PR gets merged):Partially addresses #4260.
Special notes for your reviewer:
This PR aligns worker metrics endpoints with the existing pattern:
controller-generated certificates, signed by the CDI CA, stored in Secrets and mounted into pods.
Client-side TLS verification remains unchanged. Enabling verification with the CDI CA bundle and the appropriate server identity will be tracked in a separate issue.
Validation:
using filesystem PVCs: both endpoints returned HTTP 200 with CA and
hostname verification enabled, and served the certificate stored in
their Secret.
The manual runtime checks verified metrics TLS only; they did not exercise complete imports from real oVirt or OpenStack environments.
Release note:
<!-- Write your release note:
1. Enter your extended release note in the below block. If the PR requires additional action from users switching to the new release, include the string "action required".
2. If no release note is required, just write "NONE".
-->
``
release-note
``NONE