---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
  annotations:
    controller-gen.kubebuilder.io/version: v0.17.2
  name: clusterexternaldnses.approuting.kubernetes.azure.com
spec:
  group: approuting.kubernetes.azure.com
  names:
    kind: ClusterExternalDNS
    listKind: ClusterExternalDNSList
    plural: clusterexternaldnses
    shortNames:
    - cedns
    singular: clusterexternaldns
  scope: Cluster
  versions:
  - name: v1alpha1
    schema:
      openAPIV3Schema:
        description: ClusterExternalDNS allows users to specify desired the state
          of a cluster-scoped ExternalDNS deployment and includes information about
          the state of their resources in the form of Kubernetes events.
        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: ClusterExternalDNSSpec allows users to specify desired the
              state of a cluster-scoped ExternalDNS deployment.
            properties:
              dnsZoneResourceIDs:
                description: DNSZoneResourceIDs is a list of Azure Resource IDs of
                  the DNS zones that the ExternalDNS controller should manage. These
                  must be in the same resource group and be of the same type (public
                  or private). The number of zones is currently capped at 7 but may
                  be expanded in the future.
                items:
                  type: string
                maxItems: 7
                minItems: 1
                type: array
                x-kubernetes-list-type: set
                x-kubernetes-validations:
                - message: all items must have the same subscription ID
                  rule: self.all(item, item.split('/')[2] == self[0].split('/')[2])
                - message: all items must have the same resource group
                  rule: self.all(item, item.split('/')[4] == self[0].split('/')[4])
                - message: all items must be of the same resource type
                  rule: self.all(item, item.split('/')[7] == self[0].split('/')[7])
              filters:
                description: Filters contains optional filters that the ExternalDNS
                  controller should use to determine which resources to manage.
                properties:
                  gatewayLabels:
                    description: GatewayLabelSelector is the label selector that the
                      ExternalDNS controller will use to filter the Gateways that
                      it manages.
                    pattern: ^[^=]+=[^=]+$
                    type: string
                  routeAndIngressLabels:
                    description: RouteAndIngressLabelSelector is the label selector
                      that the ExternalDNS controller will use to filter the HTTPRoutes
                      and Ingresses that it manages.
                    pattern: ^[^=]+=[^=]+$
                    type: string
                type: object
              identity:
                description: Identity contains information about the identity that
                  ExternalDNS will use to interface with Azure resources.
                properties:
                  serviceAccount:
                    description: ServiceAccount is the name of the Kubernetes ServiceAccount
                      that ExternalDNS will use to interface with Azure resources.
                      It must be in the same namespace as the ExternalDNS.
                    maxLength: 253
                    minLength: 1
                    pattern: ^[a-z0-9][-a-z0-9\.]*[a-z0-9]$
                    type: string
                required:
                - serviceAccount
                type: object
              resourceName:
                description: ResourceName is the name that will be used for the ExternalDNS
                  deployment and related resources. Will default to the name of the
                  ClusterExternalDNS resource if not specified.
                maxLength: 253
                minLength: 1
                pattern: ^[a-z0-9][-a-z0-9\.]*[a-z0-9]$
                type: string
              resourceNamespace:
                description: ResourceNamespace is the namespace where the ExternalDNS
                  resources will be deployed by app routing.
                maxLength: 253
                minLength: 1
                pattern: ^[a-z0-9][-a-z0-9\.]*[a-z0-9]$
                type: string
              resourceTypes:
                description: ResourceTypes is a list of Kubernetes resource types
                  that the ExternalDNS controller should manage. The supported resource
                  types are 'ingress' and 'gateway'.
                items:
                  type: string
                maxItems: 2
                minItems: 1
                type: array
                x-kubernetes-list-type: set
                x-kubernetes-validations:
                - message: all items must be either 'gateway' or 'ingress'
                  rule: self.all(item, item.matches('(?i)(gateway|ingress)'))
              tenantId:
                description: TenantID is the ID of the Azure tenant where the DNS
                  zones are located.
                format: uuid
                pattern: '[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}'
                type: string
            required:
            - dnsZoneResourceIDs
            - identity
            - resourceName
            - resourceNamespace
            - resourceTypes
            type: object
          status:
            description: ClusterExternalDNSStatus contains information about the state
              of the managed ExternalDNS resources.
            properties:
              collisionCount:
                description: |-
                  Count of hash collisions for the managed resources. The App Routing Operator uses this field
                  as a collision avoidance mechanism when it needs to create the name for the managed resources.
                format: int32
                maximum: 5
                type: integer
              conditions:
                description: Conditions is an array of current observed conditions
                  for the ExternalDNS
                items:
                  description: Condition contains details for one aspect of the current
                    state of this API Resource.
                  properties:
                    lastTransitionTime:
                      description: |-
                        lastTransitionTime is the last time the condition transitioned from one status to another.
                        This should be when the underlying condition changed.  If that is not known, then using the time when the API field changed is acceptable.
                      format: date-time
                      type: string
                    message:
                      description: |-
                        message is a human readable message indicating details about the transition.
                        This may be an empty string.
                      maxLength: 32768
                      type: string
                    observedGeneration:
                      description: |-
                        observedGeneration represents the .metadata.generation that the condition was set based upon.
                        For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date
                        with respect to the current state of the instance.
                      format: int64
                      minimum: 0
                      type: integer
                    reason:
                      description: |-
                        reason contains a programmatic identifier indicating the reason for the condition's last transition.
                        Producers of specific condition types may define expected values and meanings for this field,
                        and whether the values are considered a guaranteed API.
                        The value should be a CamelCase string.
                        This field may not be empty.
                      maxLength: 1024
                      minLength: 1
                      pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$
                      type: string
                    status:
                      description: status of the condition, one of True, False, Unknown.
                      enum:
                      - "True"
                      - "False"
                      - Unknown
                      type: string
                    type:
                      description: type of condition in CamelCase or in foo.example.com/CamelCase.
                      maxLength: 316
                      pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$
                      type: string
                  required:
                  - lastTransitionTime
                  - message
                  - reason
                  - status
                  - type
                  type: object
                type: array
                x-kubernetes-list-map-keys:
                - type
                x-kubernetes-list-type: map
              externalDNSReadyReplicas:
                format: int32
                type: integer
              externalDNSUnavailableReplicas:
                format: int32
                type: integer
              managedResourceRefs:
                description: ManagedResourceRefs is a list of references to the managed
                  resources
                items:
                  description: ManagedObjectReference is a reference to an object
                  properties:
                    apiGroup:
                      description: APIGroup is the API group of the managed object.
                        If not specified, the resource is in the core API group
                      type: string
                    kind:
                      description: Kind is the kind of the managed object
                      type: string
                    name:
                      description: Name is the name of the managed object
                      type: string
                    namespace:
                      description: Namespace is the namespace of the managed object.
                        If not specified, the resource is cluster-scoped
                      type: string
                  required:
                  - kind
                  - name
                  type: object
                type: array
            required:
            - externalDNSReadyReplicas
            - externalDNSUnavailableReplicas
            type: object
        required:
        - spec
        type: object
    served: true
    storage: true
    subresources:
      status: {}
