##---
# Source: olm/templates/0000_30_13-operatorgroup.crd.yaml
apiVersion: apiextensions.k8s.io/v1beta1
kind: CustomResourceDefinition
metadata:
  name: operatorgroups.operators.coreos.com
spec:
  group: operators.coreos.com
  version: v1alpha2
  versions:
  - name: v1alpha2
    served: true
    storage: true
  names:
    plural: operatorgroups
    singular: operatorgroup
    kind: OperatorGroup
    listKind: OperatorGroupList
    shortNames:
      - og
    categories:
      - olm
  scope: Namespaced
  subresources:
    # status enables the status subresource.
    status: {}
  validation:
    openAPIV3Schema:
      properties:
        spec:
          properties:
            selector:
              type: object
              description: Label selector to find resources associated with or managed by the operator
              properties:
                matchLabels:
                  type: object
                  description: Label key:value pairs to match directly
                matchExpressions:
                  type: array
                  description: A set of expressions to match against the resource.
                  items:
                    allOf:
                      - type: object
                        required:
                        - key
                        - operator
                        - values
                        properties:
                          key:
                            type: string
                            description: the key to match
                          operator:
                            type: string
                            description: the operator for the expression
                            enum:
                            - In
                            - NotIn
                            - Exists
                            - DoesNotExist
                          values:
                            type: array
                            description: set of values for the expression
            targetNamespaces:
              type: array
              items:
                type: string
                pattern: ^\S+$
            serviceAccountName:
              type: string
          type: object
        status:
          properties:
            lastUpdated:
              format: date-time
              type: string
            namespaces:
              items:
                type: string
              type: array
          required:
          - namespaces
          - lastUpdated
          type: object
      required:
      - metadata
