Skip to content

CRD: preserveUnknownFields is deprecated and should be removed #4101

@sebv7

Description

@sebv7

What steps did you take and what happened:
The spec.preserveUnknownFields has been deprecated in favor of x-kubernetes-preserve-unknown-fields: true in the CRD v1.

This means that CRD deployed with Argo CD containing spec.preserveUnknownFields: false will be out of sync. To address this problem, the preserveUnknownFields field can be removed from the CRD spec.

Anything else you would like to add:
Affects OPA Gatekeeper if deployed by Argo CD v3.0.
https://argo-cd.readthedocs.io/en/stable/operator-manual/upgrading/2.14-3.0/#removing-default-ignores-of-preserveunknownfields-for-crd

Environment:

  • Gatekeeper version: v3.20.0
  • Kubernetes version: (use kubectl version): v1.32.6

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions