apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
  name: reports.metering.openshift.io
spec:
  group: metering.openshift.io
  scope: Namespaced
  names:
    plural: reports
    singular: report
    kind: Report
  versions:
  - name: v1
    served: true
    storage: true
    additionalPrinterColumns:
    - name: Query
      type: string
      jsonPath: .spec.query
    - name: Schedule
      type: string
      jsonPath: .spec.schedule.period
    - name: Running
      type: string
      jsonPath: .status.conditions[?(@.type=="Running")].reason
    - name: Failed
      type: string
      jsonPath: .status.conditions[?(@.type=="Failure")].reason
    - name: Last Report Time
      type: string
      jsonPath: .status.lastReportTime
    - name: Age
      type: date
      jsonPath: .metadata.creationTimestamp
