Closed kdvalin closed 1 year ago
After digging around a little more, I found the issue.
There is no cluster-monitoring-view
in current release candidates of ODF 4.12.
Changing cluster-monitoring-view
in roles/datasource/tasks/main.yml
to prometheus-k8s
restores expected functionality. Will open a PR, but additional exploration will be needed for other versions of OCP.
@kdvalin is this still the case? Looking at https://docs.openshift.com/container-platform/4.12/monitoring/managing-alerts.html it appears the role is still thee in 4.12?
This does seem to be the case for the OCP 4.12 version I'm currently running.
It seems like they renamed the role to openshift-cluster-monitoring-view
, testing that now
Update: the role is still in OCP 4.12, but they removed the service account token association from within the service account's JSON, causing no token to be selected. Current PR does fix this, just want to verify everything before opening it up for merge.
@kdvalin I pushed some changes today which should fix this issue. I tested on a 4.12 system and everything appeared to work fine.
Sorry I forgot to respond to this.
The changes have fixed the issue, closing this out.
On OCP/ODF 4.12 it seems like there is some sort of update to service account token creation that breaks this process.
Current workaround I've found is:
oc get secret -n openshift-monitoring | grep prometheus-k8s-token
and copy the first columnoc get secret -n openshift-monitoring <paste output from step 1> -o json | jq -r .data.token | base64 -d
and copy the resultBearer <value from step 2>
(space is important)