CNV-101845: grant the monitoring-plugin SA the read-only RBAC required by the alerts management API #3194
All Vouch review confidence checks passed
Residual risk 0.20 = Change Risk (0.37) × (1 − Review Confidence (0.47)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.37 · 239 lines diff across 2 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.02 · 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
Shallow Review Depth
shallow_review_depth
0.344
Diff Size
diff_size
0.328
Real PR Conversation Timeline
1 comments
"Review active on #3194"
general
weight: 0.35
sradco
CMO creates the read-only RBAC that the monitoring-plugin service
account needs to serve the alerts management API. Both the RBAC
and the alert-management-api plugin flag follow the AlertManagement
feature gate (registered in openshift/api#3203) and are removed
when the gate is disabled:
alertrelabelconfigs, configmaps, leases, the
alert-relabel-configs secret and the alertmanager-main and
prometheus-k8s routes.
the alertmanager-user-workload route, created only while user
workload monitoring is enabled.
The permissions mirror what the plugin's background collectors
use (rule informers, metrics collector, health endpoint). Reads
and mutations through the API run with the requesting user's
token.
On clusters where the gate isn't registered yet, the operator
treats it as disabled. The operator also gets create/get/update
permissions on leases: RBAC's privilege escalation admission
requires it to hold every permission it grants to the plugin's
service account.
Jira: https://issues.redhat.com/browse/CNV-101845
Enhancement: openshift/enhancements#1822
Feature gate: openshift/api#3203
Plugin: openshift/monitoring-plugin#1172
Validation passed:
go build ./pkg/... ./cmd/...go vetandgo teston pkg/manifests, pkg/tasks and pkg/operatorgolangci-lint run(no new issues)yamllinton the changed assetsmake check-assetsmake jsonnet-fmtandmake build-jsonnet(generated files in sync)Telemetry report
Not applicable: this change does not modify telemetry collection selectors in
manifests/0000_50_cluster-monitoring-operator_04-config.yaml.Signed-off-by: Shirly Radco <sradco@redhat.com>
Co-authored-by: GLM <noreply@z.ai>