apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
  name: teployments.shahin.oka.com
spec:
  group: shahin.oka.com
  versions:
    - name: v1alpha1
      served: true
      storage: true
      schema:
        openAPIV3Schema:
          type: object
          properties:
            spec:
              type: object
              properties:
                replicas:
                  type: integer
                selector:
                  type: object
                  properties:
                    matchLabels:
                      type: object
                      properties:
                        app:
                          type: string
                serviceType:
                  type: string
                servicePorts:
                  type: object
                  properties:
                    port:
                      type: integer
                    targetPort:
                      type: integer
                    nodePort:
                      type: integer
                template:
                  type: object
                  properties:
                    metadata:
                      type: object
                      properties:
                        labels:
                          type: object
                          properties:
                            app:
                              type: string
                    spec:
                      type: object
                      properties:
                        containers:
                          type: object
                          properties:
                            name:
                              type: string
                            image:
                              type: string
                            ports:
                              type: object
                              properties:
                                containerPort:
                                  type: integer
  scope: Namespaced
  names:
    kind: Teployment
    plural: teployments
    singular: teployment
    shortNames:
      - teploy
