# Copyright Contributors to the Open Cluster Management project

apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
  name: workmanagers.agent.open-cluster-management.io
spec:
  group: agent.open-cluster-management.io
  names:
    kind: WorkManager
    listKind: WorkManagerList
    plural: workmanagers
    singular: workmanager
  scope: Namespaced
  versions:
  - name: v1
    schema:
      openAPIV3Schema:
        description: WorkManager is the Schema for the workmanagers API
        properties:
          apiVersion:
            description: 'APIVersion defines the versioned schema of this representation
              of an object. Servers should convert recognized schemas to the latest
              internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
            type: string
          kind:
            description: 'Kind is a string value representing the REST resource this
              object represents. Servers may infer this from the endpoint the client
              submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
            type: string
          metadata:
            type: object
          spec:
            description: WorkManagerSpec defines the desired state of WorkManager
            properties:
              clusterLabels:
                additionalProperties:
                  type: string
                type: object
              clusterName:
                minLength: 1
                type: string
              clusterNamespace:
                minLength: 1
                type: string
              fullnameOverride:
                minLength: 1
                type: string
              global:
                description: GlobalValues defines the global values
                properties:
                  imageOverrides:
                    additionalProperties:
                      type: string
                    type: object
                  imagePullPolicy:
                    description: PullPolicy describes a policy for if/when to pull
                      a container image
                    type: string
                  imagePullSecret:
                    type: string
                type: object
              hubKubeconfigSecret:
                minLength: 1
                type: string
            required:
            - clusterLabels
            - clusterName
            - clusterNamespace
            - fullnameOverride
            - hubKubeconfigSecret
            type: object
          status:
            description: WorkManagerStatus defines the observed state of WorkManager
            type: object
        type: object
    served: true
    storage: true
    subresources:
      status: {}
