apiVersion: apiextensions.k8s.io/v1beta1
kind: CustomResourceDefinition
metadata:
  name: containerruntimes.extensions.gardener.cloud
  labels:
    gardener.cloud/deletion-protected: "true"
spec:
  group: extensions.gardener.cloud
  versions:
    - name: v1alpha1
      served: true
      storage: true
  version: v1alpha1
  scope: Namespaced
  names:
    plural: containerruntimes
    singular: containerruntime
    kind: ContainerRuntime
    shortNames:
      - cr
  additionalPrinterColumns:
    - name: Type
      type: string
      description: The type of the Container Runtime resource.
      JSONPath: .spec.type
    - name: Status
      type: string
      description: Status of Extension resource.
      JSONPath: .status.lastOperation.state
    - name: Age
      type: date
      JSONPath: .metadata.creationTimestamp
  subresources:
    status: {}
  validation:
    openAPIV3Schema:
      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/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/api-conventions.md#types-kinds'
          type: string
        metadata:
          type: object
        spec:
          properties:
            type:
              description: Type contains the type of the Container Runtime.
              type: string
            binaryPath:
              description: Path to container runtime binaries folder.
              type: string
            workerPool:
              description: WorkerPool identifies the worker pool of the Shoot.
              type: object
              properties:
                name:
                  description: Name specifies the name of the worker pool the container runtime should be available for.
                  type: string
                selector:
                  description: Selector is the label selector used by the extension to match the nodes belonging to the worker pool.
                  type: object
              required:
                - name
                - selector
            providerConfig:
              description: ProviderConfig contains provider-specific configuration
                for this container runtime.
              type: object
          required:
          - type
          - binaryPath
          - workerPool