From 1ef82ab530292c86e2a73c3b16d91b302f8cfb42 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Charles-Edouard=20Br=C3=A9t=C3=A9ch=C3=A9?= Date: Mon, 25 Dec 2023 21:42:19 +0100 Subject: [PATCH] feat: stop serving v2alpha1 cleanup policies (#9270) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Charles-Edouard Brétéché --- api/kyverno/v2alpha1/cleanup_policy_types.go | 4 ++-- charts/kyverno/charts/crds/templates/crds.yaml | 6 ++---- config/crds/kyverno.io_cleanuppolicies.yaml | 3 +-- config/crds/kyverno.io_clustercleanuppolicies.yaml | 3 +-- config/install-latest-testing.yaml | 6 ++---- 5 files changed, 8 insertions(+), 14 deletions(-) diff --git a/api/kyverno/v2alpha1/cleanup_policy_types.go b/api/kyverno/v2alpha1/cleanup_policy_types.go index 0c2422bf94..4ec00debfd 100644 --- a/api/kyverno/v2alpha1/cleanup_policy_types.go +++ b/api/kyverno/v2alpha1/cleanup_policy_types.go @@ -34,7 +34,7 @@ import ( // +kubebuilder:subresource:status // +kubebuilder:printcolumn:name="Schedule",type=string,JSONPath=".spec.schedule" // +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp" -// +kubebuilder:deprecatedversion +// +kubebuilder:unservedversion // CleanupPolicy defines a rule for resource cleanup. type CleanupPolicy kyvernov2beta1.CleanupPolicy @@ -106,7 +106,7 @@ type CleanupPolicyList kyvernov2beta1.CleanupPolicyList // +kubebuilder:subresource:status // +kubebuilder:printcolumn:name="Schedule",type=string,JSONPath=".spec.schedule" // +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp" -// +kubebuilder:deprecatedversion +// +kubebuilder:unservedversion // ClusterCleanupPolicy defines rule for resource cleanup. type ClusterCleanupPolicy kyvernov2beta1.ClusterCleanupPolicy diff --git a/charts/kyverno/charts/crds/templates/crds.yaml b/charts/kyverno/charts/crds/templates/crds.yaml index cfcc1c6079..6343ea571c 100644 --- a/charts/kyverno/charts/crds/templates/crds.yaml +++ b/charts/kyverno/charts/crds/templates/crds.yaml @@ -2495,7 +2495,6 @@ spec: - jsonPath: .metadata.creationTimestamp name: Age type: date - deprecated: true name: v2alpha1 schema: openAPIV3Schema: @@ -3726,7 +3725,7 @@ spec: required: - spec type: object - served: true + served: false storage: false subresources: status: {} @@ -7470,7 +7469,6 @@ spec: - jsonPath: .metadata.creationTimestamp name: Age type: date - deprecated: true name: v2alpha1 schema: openAPIV3Schema: @@ -8701,7 +8699,7 @@ spec: required: - spec type: object - served: true + served: false storage: false subresources: status: {} diff --git a/config/crds/kyverno.io_cleanuppolicies.yaml b/config/crds/kyverno.io_cleanuppolicies.yaml index ca4a4e50d0..b1319e9be2 100644 --- a/config/crds/kyverno.io_cleanuppolicies.yaml +++ b/config/crds/kyverno.io_cleanuppolicies.yaml @@ -1266,7 +1266,6 @@ spec: - jsonPath: .metadata.creationTimestamp name: Age type: date - deprecated: true name: v2alpha1 schema: openAPIV3Schema: @@ -2497,7 +2496,7 @@ spec: required: - spec type: object - served: true + served: false storage: false subresources: status: {} diff --git a/config/crds/kyverno.io_clustercleanuppolicies.yaml b/config/crds/kyverno.io_clustercleanuppolicies.yaml index cfa9264d10..f074c60f17 100644 --- a/config/crds/kyverno.io_clustercleanuppolicies.yaml +++ b/config/crds/kyverno.io_clustercleanuppolicies.yaml @@ -1266,7 +1266,6 @@ spec: - jsonPath: .metadata.creationTimestamp name: Age type: date - deprecated: true name: v2alpha1 schema: openAPIV3Schema: @@ -2497,7 +2496,7 @@ spec: required: - spec type: object - served: true + served: false storage: false subresources: status: {} diff --git a/config/install-latest-testing.yaml b/config/install-latest-testing.yaml index 01fc54f1d4..750cb9c1ee 100644 --- a/config/install-latest-testing.yaml +++ b/config/install-latest-testing.yaml @@ -2706,7 +2706,6 @@ spec: - jsonPath: .metadata.creationTimestamp name: Age type: date - deprecated: true name: v2alpha1 schema: openAPIV3Schema: @@ -3937,7 +3936,7 @@ spec: required: - spec type: object - served: true + served: false storage: false subresources: status: {} @@ -7687,7 +7686,6 @@ spec: - jsonPath: .metadata.creationTimestamp name: Age type: date - deprecated: true name: v2alpha1 schema: openAPIV3Schema: @@ -8918,7 +8916,7 @@ spec: required: - spec type: object - served: true + served: false storage: false subresources: status: {}