cuelang.org/go@v0.13.0/encoding/jsonschema/testdata/txtar/crd_ref.txtar (about)

     1  CRDs do not allow $ref, so test for that.
     2  
     3  #version: k8sCRD
     4  
     5  -- schema.yaml --
     6  apiVersion: apiextensions.k8s.io/v1
     7  kind: CustomResourceDefinition
     8  metadata:
     9    # name must be in the form: <plural>.<group>
    10    name: myapps.example.com
    11  spec:
    12    # group name to use for REST API: /apis/<group>/<version>
    13    group: example.com
    14    scope: Namespaced
    15    names:
    16      # kind is normally the CamelCased singular type.
    17      kind: MyApp
    18      # singular name to be used as an alias on the CLI
    19      singular: myapp
    20      # plural name in the URL: /apis/<group>/<version>/<plural>
    21      plural: myapps
    22    versions:
    23    - name: v1
    24      served: true
    25      storage: true
    26      schema:
    27        openAPIV3Schema:
    28          type: object
    29          properties:
    30            spec:
    31              $ref: "#/something"
    32  
    33  -- out/decode/extract --
    34  ERROR:
    35  keyword "$ref" is not supported in JSON schema version Kubernetes CRD:
    36      schema.yaml:26:13