{
  "description": "NamespacedControllerResource is the Schema for resource customization API for namespaced config connector controllers.",
  "properties": {
    "apiVersion": {
      "description": "APIVersion defines the versioned schema of this representation of an object.\nServers should convert recognized schemas to the latest internal value, and\nmay reject unrecognized values.\nMore 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.\nServers may infer this from the endpoint the client submits requests to.\nCannot be updated.\nIn CamelCase.\nMore info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds",
      "type": "string"
    },
    "metadata": {
      "properties": {
        "name": {
          "enum": [
            "cnrm-controller-manager"
          ],
          "type": "string"
        }
      },
      "type": "object",
      "additionalProperties": false
    },
    "spec": {
      "description": "NamespacedControllerResourceSpec is the specification of the resource customization for containers of\na namespaced config connector controller.",
      "properties": {
        "containers": {
          "description": "The list of containers whose resource requirements to be customized.",
          "items": {
            "description": "ContainerResourceSpec is the specification of the resource customization for a container of\na config connector controller.",
            "properties": {
              "name": {
                "description": "The name of the container whose resource requirements will be customized.\nRequired",
                "enum": [
                  "manager",
                  "webhook",
                  "deletiondefender",
                  "prom-to-sd",
                  "recorder",
                  "unmanageddetector"
                ],
                "type": "string"
              },
              "resources": {
                "description": "Resources specifies the resource customization of this container.\nRequired",
                "properties": {
                  "limits": {
                    "additionalProperties": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "string"
                        }
                      ],
                      "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$",
                      "x-kubernetes-int-or-string": true
                    },
                    "description": "Limits describes the maximum amount of compute resources allowed.\nMore info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/",
                    "type": "object"
                  },
                  "requests": {
                    "additionalProperties": {
                      "anyOf": [
                        {
                          "type": "integer"
                        },
                        {
                          "type": "string"
                        }
                      ],
                      "pattern": "^(\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\\+|-)?(([0-9]+(\\.[0-9]*)?)|(\\.[0-9]+))))?$",
                      "x-kubernetes-int-or-string": true
                    },
                    "description": "Requests describes the minimum amount of compute resources required.\nIf Requests is omitted for a container, it defaults to Limits if that is explicitly specified,\notherwise to an implementation-defined value. Requests cannot exceed Limits.\nMore info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/",
                    "type": "object"
                  }
                },
                "type": "object",
                "additionalProperties": false
              }
            },
            "required": [
              "name",
              "resources"
            ],
            "type": "object",
            "additionalProperties": false
          },
          "type": "array"
        },
        "verticalPodAutoscalerMode": {
          "default": "Disabled",
          "description": "VerticalPodAutoscalerMode indicates the mode of Vertical Pod Autoscaler for the controller.",
          "enum": [
            "Enabled",
            "Disabled"
          ],
          "type": "string"
        }
      },
      "type": "object",
      "x-kubernetes-validations": [
        {
          "message": "VerticalPodAutoscalerMode cannot be Enabled when Containers are specified",
          "rule": "!has(self.verticalPodAutoscalerMode) || self.verticalPodAutoscalerMode == 'Disabled' || !has(self.containers) || size(self.containers) == 0"
        }
      ],
      "additionalProperties": false
    },
    "status": {
      "description": "NamespacedControllerResourceStatus defines the observed state of NamespacedControllerResource.",
      "properties": {
        "errors": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "healthy": {
          "type": "boolean"
        },
        "observedGeneration": {
          "default": 0,
          "format": "int64",
          "type": "integer"
        },
        "phase": {
          "type": "string"
        }
      },
      "required": [
        "healthy",
        "observedGeneration"
      ],
      "type": "object",
      "additionalProperties": false
    }
  },
  "required": [
    "spec"
  ],
  "type": "object"
}
