-
Bug
-
Resolution: Unresolved
-
Undefined
-
None
-
4.21
-
None
-
Quality / Stability / Reliability
-
False
-
-
None
-
Low
-
None
-
None
-
None
-
None
-
None
-
None
-
None
-
None
-
None
-
None
-
None
Description of problem
While checking oc adm inspect clusteroperator output in CI, I noticed that many components install ClusterRoles via release image manifests, but fail to mention them in their ClusterOperator's relatedObjects. The cloud-controller-manager ClusterOperator is one of these, with https://amd64.ocp.releases.ci.openshift.org/ > 4-dev-preview > 4.21.0-ec.2 > aws-ovn-serial-1of2 > Artifacts > inspected ClusterOperators:
$ curl -s https://gcsweb-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/test-platform-results/logs/periodic-ci-openshift-release-master-nightly-4.21-e2e-aws-ovn-serial-1of2/1980906989932253184/artifacts/e2e-aws-ovn-serial/gather-extra/artifacts/inspect/cluster-scoped-resources/config.openshift.io/clusteroperators/cloud-controller-manager.yaml | yaml2json | jq -c '.status.relatedObjects[]'
{"group":"","name":"openshift-cloud-controller-manager-operator","resource":"namespaces"}
{"group":"config.openshift.io","name":"cloud-controller-manager","resource":"clusteroperators"}
{"group":"","name":"openshift-cloud-controller-manager","resource":"namespaces"}
despite requesting a cloud-controller-manager ClusterRole. To facilitate the gathering of resources relevant to the component, the ClusterOperator's relatedObjects should be expanded to reference that ClusterRole, and any other resources that might be relevant to debugging the component, as described in the ClusterOperator docs. Note that some inspect lookup is implicit as part of a namespace reference, but that will obviously not pick up resources that are cluster scoped, like ClusterRole.
Version-Release number of selected component
Seen in 4.21.0-ec.2 CI. Likely applies to many other versions, but I have not audited.
How reproducible
Every time.
Steps to Reproduce
1. Install a cluster.
2. Inspect the ClusterOperator: oc adm inspect clusteroperator/cloud-controller-manager.
3. Ensure all the resources relevant to debugging that component are present in the output.
Actual results
$ ls inspect.local.*/cluster-scoped-resources/ config.openshift.io operator.openshift.io
Expected results
cluster-scoped-resources/rbac.authorization.k8s.io/clusterroles/cloud-controller-manager.yaml should be collected, along with any other cluster-scoped resources which would be useful for debugging the component.
Additional info
In addition to expanding relatedObjects in your reconciled ClusterOperator status (likely Go code in your controller), you may want to extend the entries in your ClusterOperator release image manifest. Definitely expand the manifest if you think you might need the resource collected to debug "why is my Go controller failing to update ClusterOperator status.relatedObjects?", so the CVO can put that entry in place if your operator fails to install.
- is cloned by
-
OCPBUGS-65488 network ClusterOperator relatedObjects missing cluster-network-operator ClusterRoleBinding
-
- New
-
-
OCPBUGS-65504 machine-config ClusterOperator relatedObjects missing ClusterRoleBinding
-
- New
-
-
OCPBUGS-65470 authentication ClusterOperator relatedObjects missing ClusterRoleBinding
-
- New
-
-
OCPBUGS-65471 cluster-autoscaler ClusterOperator relatedObjects missing ClusterRole
-
- New
-
-
OCPBUGS-65472 baremetal ClusterOperator relatedObjects missing ClusterRole
-
- New
-
-
OCPBUGS-65475 image-registry ClusterOperator relatedObjects missing ClusterRole
-
- New
-
-
OCPBUGS-65476 ingress ClusterOperator relatedObjects missing ClusterRole
-
- New
-
-
OCPBUGS-65483 kube-storage-version-migrator ClusterOperator relatedObjects missing ClusterRoleBinding
-
- New
-
-
OCPBUGS-65490 openshift-apiserver ClusterOperator relatedObjects missing ClusterRoleBinding
-
- New
-
-
OCPBUGS-65491 openshift-controller-manager ClusterOperator relatedObjects missing ClusterRoleBinding
-
- New
-
-
OCPBUGS-65493 openshift-samples ClusterOperator relatedObjects missing ClusterRole
-
- New
-
-
OCPBUGS-65495 config-operator ClusterOperator relatedObjects missing ClusterRoleBinding
-
- New
-
-
OCPBUGS-65498 dns ClusterOperator relatedObjects missing ClusterRole
-
- New
-
-
OCPBUGS-65499 etcd ClusterOperator relatedObjects missing ClusterRoleBinding
-
- New
-
-
OCPBUGS-65500 insights ClusterOperator relatedObjects missing ClusterRole
-
- New
-
-
OCPBUGS-65501 kube-apiserver ClusterOperator relatedObjects missing ClusterRoleBinding
-
- New
-
-
OCPBUGS-65505 olm ClusterOperator relatedObjects missing ClusterRole
-
- New
-
-
OCPBUGS-65506 service-ca ClusterOperator relatedObjects missing ClusterRoleBinding
-
- New
-
-
OCPBUGS-65474 csi-snapshot-controller ClusterOperator relatedObjects missing ClusterRole
-
- ASSIGNED
-
-
OCPBUGS-65485 monitoring ClusterOperator relatedObjects missing ClusterRole
-
- ASSIGNED
-
-
OCPBUGS-65496 console ClusterOperator relatedObjects missing ClusterRole
-
- ASSIGNED
-
-
OCPBUGS-65484 machine-approver ClusterOperator relatedObjects missing ClusterRole
-
- POST
-
-
OCPBUGS-65497 control-plane-machine-set ClusterOperator relatedObjects missing ClusterRole
-
- POST
-
-
OCPBUGS-65502 kube-controller-manager ClusterOperator relatedObjects missing ClusterRoleBinding
-
- POST
-
-
OCPBUGS-65503 kube-scheduler ClusterOperator relatedObjects missing ClusterRoleBinding
-
- POST
-
-
OCPBUGS-65489 node-tuning ClusterOperator relatedObjects missing ClusterRole
-
- MODIFIED
-
- links to