compliance-operator icon indicating copy to clipboard operation
compliance-operator copied to clipboard

CMP-2615: Add a check aggregate to the compliance scan metadata

Open Vincent056 opened this issue 6 months ago • 8 comments

Implement a total check count as an annotation of the ComplianceScan, we will add an annotation compliance.openshift.io/check-count to every compliancescan object when a scan is in Done state.

Noted: This annotation is removed when a new scanPhase begins.

example of output

[vincent@node test-file]$ oc get scan ocp4-cis -o yaml
apiVersion: compliance.openshift.io/v1alpha1
kind: ComplianceScan
metadata:
  annotations:
    compliance.openshift.io/check-count: "89"
  creationTimestamp: "2024-08-15T04:42:36Z"
  finalizers:
  - scan.finalizers.compliance.openshift.io
  generation: 1
  labels:
    compliance.openshift.io/profile-guid: a230315d-3e4a-5b58-b00f-f96f1553e036
    compliance.openshift.io/suite: ocp4-cis-ssb
  name: ocp4-cis

Vincent056 avatar Aug 13 '24 16:08 Vincent056