mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-29 14:37:00 +00:00
apiextensions: document that webhook conversion requires preserveUnknownFields=false
This commit is contained in:
parent
333f6391ed
commit
83322bd928
@ -85,7 +85,8 @@ type CustomResourceDefinitionSpec struct {
|
|||||||
type CustomResourceConversion struct {
|
type CustomResourceConversion struct {
|
||||||
// `strategy` specifies the conversion strategy. Allowed values are:
|
// `strategy` specifies the conversion strategy. Allowed values are:
|
||||||
// - `None`: The converter only change the apiVersion and would not touch any other field in the CR.
|
// - `None`: The converter only change the apiVersion and would not touch any other field in the CR.
|
||||||
// - `Webhook`: API Server will call to an external webhook to do the conversion. Additional information is needed for this option.
|
// - `Webhook`: API Server will call to an external webhook to do the conversion. Additional information
|
||||||
|
// is needed for this option. This requires spec.preserveUnknownFields to be false.
|
||||||
Strategy ConversionStrategyType
|
Strategy ConversionStrategyType
|
||||||
|
|
||||||
// `webhookClientConfig` is the instructions for how to call the webhook if strategy is `Webhook`.
|
// `webhookClientConfig` is the instructions for how to call the webhook if strategy is `Webhook`.
|
||||||
|
@ -90,7 +90,8 @@ type CustomResourceDefinitionSpec struct {
|
|||||||
type CustomResourceConversion struct {
|
type CustomResourceConversion struct {
|
||||||
// `strategy` specifies the conversion strategy. Allowed values are:
|
// `strategy` specifies the conversion strategy. Allowed values are:
|
||||||
// - `None`: The converter only change the apiVersion and would not touch any other field in the CR.
|
// - `None`: The converter only change the apiVersion and would not touch any other field in the CR.
|
||||||
// - `Webhook`: API Server will call to an external webhook to do the conversion. Additional information is needed for this option.
|
// - `Webhook`: API Server will call to an external webhook to do the conversion. Additional information
|
||||||
|
// is needed for this option. This requires spec.preserveUnknownFields to be false.
|
||||||
Strategy ConversionStrategyType `json:"strategy" protobuf:"bytes,1,name=strategy"`
|
Strategy ConversionStrategyType `json:"strategy" protobuf:"bytes,1,name=strategy"`
|
||||||
|
|
||||||
// `webhookClientConfig` is the instructions for how to call the webhook if strategy is `Webhook`. This field is
|
// `webhookClientConfig` is the instructions for how to call the webhook if strategy is `Webhook`. This field is
|
||||||
|
Loading…
Reference in New Issue
Block a user