apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
  name: dashboardconfigs.dashboard.liqo.io
spec:
  group: dashboard.liqo.io
  scope: Cluster
  names:
    plural: dashboardconfigs
    singular: dashboardconfig
    kind: DashboardConfig
    listKind: DashboardConfigList
  versions:
  - name: v1alpha1
    schema:
      openAPIV3Schema:
          type: object
          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-architectur\
                e/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-architectur\
                e/api-conventions.md#types-kinds"
              type: string
            metadata:
              type: object
            spec:
              type: object
              properties:
                default:
                  type: boolean
                enabled:
                  type: boolean
                plugin:
                  type: array
                  items:
                    type: object
                    properties:
                      URL:
                        type: string
                      enabled:
                        type: boolean
                      path:
                        type: string  
                role:
                  type: object
                  properties:
                    roleName:
                      type: string
                    roleType:
                      type: string
                footer:
                  type: object
                  properties:
                    enabled:
                      type: boolean
                    footerDescription:
                      type: string
                    githubRef:
                      type: boolean
                    link:
                      type: string
                header:
                  type: object
                  properties:
                    alternativeLogo:
                      type: string
                    alternativeTitle:
                      type: string
                    menu:
                      type: array
                      items:
                        type: object
                        properties:
                          enabled:
                            type: boolean
                          icon:
                            type: string
                          itemDescription:
                            type: string
                          link:
                            type: string
                    namespaceSelector:
                      type: boolean
                    resourceSearch:
                      type: boolean
                    themeModifier:
                      type: boolean
                    themeSwitcher:
                      type: boolean
                resources:
                  type: array
                  items:
                    type: object
                    properties:
                      favourite:
                        type: boolean
                      icon:
                        type: string
                      render:
                        type: object
                        properties:
                          columns:
                            type: array
                            items:
                              type: object
                              properties:
                                columnContent:
                                  type: string
                                columnTitle:
                                  type: string
                          tabs:
                            type: array
                            items:
                              type: object
                              properties:
                                tabContent:
                                  type: array
                                  items:
                                    type: object
                                    properties:
                                      cardContent:
                                        type: array
                                        items:
                                          type: object
                                          properties:
                                            parameter:
                                              type: string
                                      cardDisplay:
                                        type: string
                                      cardLayout:
                                        type: object
                                        properties:
                                          h:
                                            type: integer
                                          w:
                                            type: integer
                                          x:
                                            type: integer
                                          "y":
                                            type: integer
                                      cardTitle:
                                        type: string
                                tabTitle:
                                  type: string
                      resourceName:
                        type: string
                      resourcePath:
                        type: string
                sidebar:
                  type: object
                  properties:
                    alternativeLogo:
                      type: string
                    alternativeTitle:
                      type: string
                    enabled:
                      type: boolean
                    menu:
                      type: array
                      items:
                        type: object
                        properties:
                          enabled:
                            type: boolean
                          icon:
                            type: string
                          itemDescription:
                            type: string
                          link:
                            type: string
    served: true
    storage: true
    subresources:
      status: {}
