From 43de92d7b1c579ec87e5c5cdac2c8890e92e854a Mon Sep 17 00:00:00 2001 From: Maksim Fedotov Date: Wed, 15 Sep 2021 19:11:45 +0300 Subject: [PATCH] build(helm): Namespace labeling for tenant owners --- charts/capsule/crds/tenant-crd.yaml | 40 +++++++++++++++++++ .../mutatingwebhookconfiguration.yaml | 1 + 2 files changed, 41 insertions(+) diff --git a/charts/capsule/crds/tenant-crd.yaml b/charts/capsule/crds/tenant-crd.yaml index 7039e41be..7b72f9a88 100644 --- a/charts/capsule/crds/tenant-crd.yaml +++ b/charts/capsule/crds/tenant-crd.yaml @@ -785,6 +785,46 @@ spec: format: int32 minimum: 1 type: integer + userAnnotations: + description: Specifies allowed annotations the Tenant owner can place on any Namespace resource in the Tenant. Optional. + properties: + allowedLabels: + properties: + allowed: + items: + type: string + type: array + allowedRegex: + type: string + type: object + protectedLabels: + properties: + protected: + items: + type: string + type: array + type: object + type: object + userLabels: + description: Specifies allowed labels the Tenant owner can place on any Namespace resource in the Tenant. Optional. + properties: + allowedLabels: + properties: + allowed: + items: + type: string + type: array + allowedRegex: + type: string + type: object + protectedLabels: + properties: + protected: + items: + type: string + type: array + type: object + type: object type: object networkPolicies: description: Specifies the NetworkPolicies assigned to the Tenant. The assigned NetworkPolicies are inherited by any namespace created in the Tenant. Optional. diff --git a/charts/capsule/templates/mutatingwebhookconfiguration.yaml b/charts/capsule/templates/mutatingwebhookconfiguration.yaml index 42f4f7bcb..76213f0f8 100644 --- a/charts/capsule/templates/mutatingwebhookconfiguration.yaml +++ b/charts/capsule/templates/mutatingwebhookconfiguration.yaml @@ -32,6 +32,7 @@ webhooks: - v1 operations: - CREATE + - UPDATE resources: - namespaces scope: '*'