From d0c164a83d274897077b05881d5eb7ef92261802 Mon Sep 17 00:00:00 2001 From: Alexey Kazakov Date: Thu, 15 Aug 2024 16:23:40 -0700 Subject: [PATCH] Add target cluster to social event (#440) --- api/v1alpha1/docs/apiref.adoc | 3 ++- api/v1alpha1/socialevent_types.go | 5 +++-- api/v1alpha1/zz_generated.openapi.go | 6 +++--- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/api/v1alpha1/docs/apiref.adoc b/api/v1alpha1/docs/apiref.adoc index 33d0aec8..7983142c 100644 --- a/api/v1alpha1/docs/apiref.adoc +++ b/api/v1alpha1/docs/apiref.adoc @@ -2382,7 +2382,8 @@ may register for the event by using the event's unique activation code This must be the valid name of an nstemplatetier resource. + | | | *`spaceTier`* __string__ | The tier to assign to spaces created for users who registered for the event. + This must be the valid name of an nstemplatetier resource. + | | -| *`preferSameCluster`* __boolean__ | If true, best effort is made to provision all attendees of the event on the same cluster + | | +| *`targetCluster`* __string__ | The cluster in which the user/space should be provisioned in + +If not set then the target cluster will be picked automatically + | | | *`verificationRequired`* __boolean__ | If true, the user will also be required to complete standard phone verification + | | |=== diff --git a/api/v1alpha1/socialevent_types.go b/api/v1alpha1/socialevent_types.go index d5d69325..846b9479 100644 --- a/api/v1alpha1/socialevent_types.go +++ b/api/v1alpha1/socialevent_types.go @@ -46,9 +46,10 @@ type SocialEventSpec struct { // This must be the valid name of an nstemplatetier resource. SpaceTier string `json:"spaceTier"` - // If true, best effort is made to provision all attendees of the event on the same cluster + // The cluster in which the user/space should be provisioned in + // If not set then the target cluster will be picked automatically // +optional - PreferSameCluster bool `json:"preferSameCluster,omitempty"` + TargetCluster string `json:"targetCluster,omitempty"` // If true, the user will also be required to complete standard phone verification // +optional diff --git a/api/v1alpha1/zz_generated.openapi.go b/api/v1alpha1/zz_generated.openapi.go index f1d0059f..91d99004 100644 --- a/api/v1alpha1/zz_generated.openapi.go +++ b/api/v1alpha1/zz_generated.openapi.go @@ -3294,10 +3294,10 @@ func schema_codeready_toolchain_api_api_v1alpha1_SocialEventSpec(ref common.Refe Format: "", }, }, - "preferSameCluster": { + "targetCluster": { SchemaProps: spec.SchemaProps{ - Description: "If true, best effort is made to provision all attendees of the event on the same cluster", - Type: []string{"boolean"}, + Description: "The cluster in which the user/space should be provisioned in If not set then the target cluster will be picked automatically", + Type: []string{"string"}, Format: "", }, },