You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ceph: preserve volume claim template metadata in schema
The schema generation was not generating the metadata properties
under the VolumeClaimTemplate type, resulting in the properties being
ignored by the api server. The preserve unknown fields tag was
not working recursively on the volumeClaimTemplates since the subtypes
were defined. Now we post-process the schema so we can preserve
the unknown fields for the volume claim templates metadata.
We now use 'yq' to hot-fix the CRDs, the only 'downside' is that 'yq'
will not preserve the existing formatting, this is a known problem:
mikefarah/yq#465
Signed-off-by: Sébastien Han <[email protected]>
Copy file name to clipboardExpand all lines: cluster/charts/rook-ceph/templates/resources.yaml
+5
Original file line number
Diff line number
Diff line change
@@ -818,6 +818,7 @@ spec:
818
818
metadata:
819
819
description: 'Standard object''s metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata'
820
820
type: object
821
+
x-kubernetes-preserve-unknown-fields: true
821
822
spec:
822
823
description: 'Spec defines the desired characteristics of a volume requested by a pod author. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims'
823
824
properties:
@@ -972,6 +973,7 @@ spec:
972
973
metadata:
973
974
description: 'Standard object''s metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata'
974
975
type: object
976
+
x-kubernetes-preserve-unknown-fields: true
975
977
spec:
976
978
description: 'Spec defines the desired characteristics of a volume requested by a pod author. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims'
977
979
properties:
@@ -1793,6 +1795,7 @@ spec:
1793
1795
metadata:
1794
1796
description: 'Standard object''s metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata'
1795
1797
type: object
1798
+
x-kubernetes-preserve-unknown-fields: true
1796
1799
spec:
1797
1800
description: 'Spec defines the desired characteristics of a volume requested by a pod author. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims'
1798
1801
properties:
@@ -2839,6 +2842,7 @@ spec:
2839
2842
metadata:
2840
2843
description: 'Standard object''s metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata'
2841
2844
type: object
2845
+
x-kubernetes-preserve-unknown-fields: true
2842
2846
spec:
2843
2847
description: 'Spec defines the desired characteristics of a volume requested by a pod author. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims'
2844
2848
properties:
@@ -3004,6 +3008,7 @@ spec:
3004
3008
metadata:
3005
3009
description: 'Standard object''s metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata'
3006
3010
type: object
3011
+
x-kubernetes-preserve-unknown-fields: true
3007
3012
spec:
3008
3013
description: 'Spec defines the desired characteristics of a volume requested by a pod author. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims'
0 commit comments