-
Bug
-
Resolution: Not a Bug
-
Major
-
None
-
4.17.z
-
Quality / Stability / Reliability
-
False
-
-
None
-
None
-
None
-
None
-
None
-
None
-
None
-
Customer Escalated
-
None
-
None
-
None
-
None
-
None
-
None
-
None
Description of problem:
The HyperShift operator periodically overwrites user-defined modifications in the cluster-monitoring-config ConfigMap within a hosted control plane's openshift-monitoring namespace.
Steps to Reproduce:
1. Deploy a HyperShift Hosted Control Plane (HCP).
2. In the hosted cluster, modify the cluster-monitoring-config ConfigMap in the openshift-monitoring namespace to include custom settings. For example, apply the following configuration:
apiVersion: v1
kind: ConfigMap
metadata:
name: cluster-monitoring-config
namespace: openshift-monitoring
data:
config.yaml: |
alertmanagerMain:
volumeClaimTemplate:
spec:
resources:
requests:
cpu: 90m
memory: 1Gi
storage: 10Gi
prometheusK8s:
retention: 24h
retentionSize: 10GB
volumeClaimTemplate:
spec:
resources:
requests:
cpu: 90m
memory: 1Gi
storage: 100Gi
limits:
cpu: 120m
memory: 2Gi
3. Wait for the HyperShift operator's reconciliation loop to run (observed to take approximately one hour).
4. Inspect the cluster-monitoring-config ConfigMap again: oc get cm cluster-monitoring-config -n openshift-monitoring -o yaml
Actual results:
The custom settings for alertmanagerMain and prometheusK8s are removed. The ConfigMap is overwritten and contains only the settings managed by HyperShift, losing all other configurations.
The resulting ConfigMap appears as follows:
kind: ConfigMap apiVersion: v1 metadata: name: cluster-monitoring-config namespace: openshift-monitoring uid: eb93ac01-726f-4d2c-95d4-0a584bdef699 resourceVersion: '210370596' creationTimestamp: '2025-08-27T14:42:56Z' managedFields: - manager: hypershift-operator-manager operation: Update apiVersion: v1 time: '2025-08-27T15:44:06Z' data: config.yaml: | enableUserWorkload: true prometheusOperator: logLevel: debug
Expected results:
The HyperShift operator's reconciliation logic should be non-destructive. It should apply its required configuration while preserving any other existing, user-defined fields in the config.yaml data.The operator should merge its required configuration (e.g., enableUserWorkload: true) with any existing settings. Modifications to the ConfigMap should be additive, not a full replacement of the data block.