From 99db6193a059ba2787618b436591e996e560c23c Mon Sep 17 00:00:00 2001 From: Robert Volkmann Date: Thu, 21 Nov 2024 09:12:35 +0100 Subject: [PATCH] Test without any tenant annotation --- pkg/admission/validator/shoot.go | 9 --------- 1 file changed, 9 deletions(-) diff --git a/pkg/admission/validator/shoot.go b/pkg/admission/validator/shoot.go index 291e5f6e..54ca79a7 100644 --- a/pkg/admission/validator/shoot.go +++ b/pkg/admission/validator/shoot.go @@ -56,11 +56,6 @@ func (s *shoot) validateShoot(ctx context.Context, shoot *core.Shoot) error { // Provider validation fldPath := field.NewPath("spec", "provider") - _, ok := shoot.Annotations[tag.ClusterTenant] - if !ok { - return field.Required(field.NewPath("metadata", "annotations"), fmt.Sprintf("cluster must be annotated with a tenant using the annotations: %s", tag.ClusterTenant)) - } - // InfrastructureConfig infraConfigFldPath := fldPath.Child("infrastructureConfig") @@ -152,10 +147,6 @@ func (s *shoot) validateShootUpdate(ctx context.Context, oldShoot, shoot *core.S } } - if shoot.Annotations[tag.ClusterTenant] != oldShoot.Annotations[tag.ClusterTenant] { - return field.Forbidden(field.NewPath("metadata", "annotations"), "tenant annotation of a shoot is immutable") - } - return s.validateShoot(ctx, shoot) }