core: skip counting exporter pods as a ceph pod

The exporter pods were being counted as a ceph pod,
so once an exporter pod was added to a node, it would never
be removed since the controller thinks the exporter pod
itself is a ceph pod for which the exporter must be present.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
This commit is contained in:
Travis Nielsen committed 2024-10-14 21:32:22 -06:00
1 parent 1433587457
commit a71078b733
1 file changed
+2 -1
+2 -1
View File
@@ -177,7 +177,8 @@ func isCephPod(labels map[string]string, podName string) bool {
// will be empty since the monitors don't exist yet
isCanaryPod := strings.Contains(podName, "-canary-")
isCrashCollectorPod := strings.Contains(podName, "-crashcollector-")
if ok && !isCanaryPod && !isCrashCollectorPod {
isExporterPod := strings.Contains(podName, "-exporter-")
if ok && !isCanaryPod && !isCrashCollectorPod && !isExporterPod {
logger.Debugf("%q is a ceph pod!", podName)
return true
}