--- apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: controller-gen.kubebuilder.io/version: v0.17.3 name: apiconversions.apis.kcp.io spec: group: apis.kcp.io names: categories: - kcp kind: APIConversion listKind: APIConversionList plural: apiconversions singular: apiconversion scope: Cluster versions: - additionalPrinterColumns: - jsonPath: .metadata.creationTimestamp name: Age type: date name: v1alpha1 schema: openAPIV3Schema: description: |- APIConversion contains rules to convert between different API versions in an APIResourceSchema. The name must match the name of the APIResourceSchema for the conversions to take effect. 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: Spec holds the desired state. properties: conversions: description: conversions specify rules to convert between different API versions in an APIResourceSchema. items: description: |- APIVersionConversion contains rules to convert between two specific API versions in an APIResourceSchema. Additionally, to avoid data loss when round-tripping from a version that contains a new field to one that doesn't and back again, you can specify a list of fields to preserve (these are stored in annotations). properties: from: description: from is the source version. minLength: 1 pattern: ^v[1-9][0-9]*([a-z]+[1-9][0-9]*)?$ type: string preserve: description: |- preserve contains a list of JSONPath expressions to fields to preserve in the originating version of the object, relative to its root, such as '.spec.name.first'. items: type: string type: array rules: description: rules contains field-specific conversion expressions. items: description: APIConversionRule specifies how to convert a single field. properties: destination: description: |- destination is a JSONPath expression to the field in the target version of the object, relative to its root, such as '.spec.name.first'. minLength: 1 type: string field: description: |- field is a JSONPath expression to the field in the originating version of the object, relative to its root, such as '.spec.name.first'. minLength: 1 type: string transformation: description: |- transformation is an optional CEL expression used to execute user-specified rules to transform the originating field -- identified by 'self' -- to the destination field. type: string required: - destination - field type: object type: array x-kubernetes-list-map-keys: - destination x-kubernetes-list-type: map to: description: to is the target version. minLength: 1 pattern: ^v[1-9][0-9]*([a-z]+[1-9][0-9]*)?$ type: string required: - from - rules - to type: object type: array x-kubernetes-list-map-keys: - from - to x-kubernetes-list-type: map required: - conversions type: object required: - metadata - spec type: object served: true storage: true subresources: {}