From 31aa19d176f6f465d6c7e3d47d66cc15a5157acd Mon Sep 17 00:00:00 2001 From: Faeka Ansari Date: Thu, 21 Nov 2024 02:58:36 +0530 Subject: [PATCH] fix: missing enumerated values in generated docs for warehouse (#2969) Signed-off-by: Faeka Ansari (cherry picked from commit 27f501cf90e48009b6f4db3cbaf39bf48329ae34) --- api/v1alpha1/generated.proto | 3 +++ api/v1alpha1/warehouse_types.go | 3 +++ charts/kargo/resources/crds/kargo.akuity.io_warehouses.yaml | 3 +++ ui/src/gen/schema/warehouses.kargo.akuity.io_v1alpha1.json | 6 +++--- ui/src/gen/v1alpha1/generated_pb.ts | 3 +++ 5 files changed, 15 insertions(+), 3 deletions(-) diff --git a/api/v1alpha1/generated.proto b/api/v1alpha1/generated.proto index 0f6695441..c720e9948 100644 --- a/api/v1alpha1/generated.proto +++ b/api/v1alpha1/generated.proto @@ -457,6 +457,7 @@ message GitSubscription { // commit of interest in the repository specified by the RepoURL field. This // field is optional. When left unspecified, the field is implicitly treated // as if its value were "NewestFromBranch". + // Accepted values: Lexical, NewestFromBranch, NewestTag, SemVer // // +kubebuilder:default=NewestFromBranch optional string commitSelectionStrategy = 2; @@ -655,6 +656,7 @@ message ImageSubscription { // of the image specified by the RepoURL field. This field is optional. When // left unspecified, the field is implicitly treated as if its value were // "SemVer". + // Accepted values: Digest, Lexical, NewestBuild, SemVer // // +kubebuilder:default=SemVer optional string imageSelectionStrategy = 3; @@ -1141,6 +1143,7 @@ message WarehouseSpec { // FreightCreationPolicy describes how Freight is created by this Warehouse. // This field is optional. When left unspecified, the field is implicitly // treated as if its value were "Automatic". + // Accepted values: Automatic, Manual // // +kubebuilder:default=Automatic // +kubebuilder:validation:Optional diff --git a/api/v1alpha1/warehouse_types.go b/api/v1alpha1/warehouse_types.go index 2e0bb1c20..063165c95 100644 --- a/api/v1alpha1/warehouse_types.go +++ b/api/v1alpha1/warehouse_types.go @@ -67,6 +67,7 @@ type WarehouseSpec struct { // FreightCreationPolicy describes how Freight is created by this Warehouse. // This field is optional. When left unspecified, the field is implicitly // treated as if its value were "Automatic". + // Accepted values: Automatic, Manual // // +kubebuilder:default=Automatic // +kubebuilder:validation:Optional @@ -111,6 +112,7 @@ type GitSubscription struct { // commit of interest in the repository specified by the RepoURL field. This // field is optional. When left unspecified, the field is implicitly treated // as if its value were "NewestFromBranch". + // Accepted values: Lexical, NewestFromBranch, NewestTag, SemVer // // +kubebuilder:default=NewestFromBranch CommitSelectionStrategy CommitSelectionStrategy `json:"commitSelectionStrategy,omitempty" protobuf:"bytes,2,opt,name=commitSelectionStrategy"` @@ -224,6 +226,7 @@ type ImageSubscription struct { // of the image specified by the RepoURL field. This field is optional. When // left unspecified, the field is implicitly treated as if its value were // "SemVer". + // Accepted values: Digest, Lexical, NewestBuild, SemVer // // +kubebuilder:default=SemVer ImageSelectionStrategy ImageSelectionStrategy `json:"imageSelectionStrategy,omitempty" protobuf:"bytes,3,opt,name=imageSelectionStrategy"` diff --git a/charts/kargo/resources/crds/kargo.akuity.io_warehouses.yaml b/charts/kargo/resources/crds/kargo.akuity.io_warehouses.yaml index 08f91a735..70ab1811e 100644 --- a/charts/kargo/resources/crds/kargo.akuity.io_warehouses.yaml +++ b/charts/kargo/resources/crds/kargo.akuity.io_warehouses.yaml @@ -52,6 +52,7 @@ spec: FreightCreationPolicy describes how Freight is created by this Warehouse. This field is optional. When left unspecified, the field is implicitly treated as if its value were "Automatic". + Accepted values: Automatic, Manual enum: - Automatic - Manual @@ -161,6 +162,7 @@ spec: commit of interest in the repository specified by the RepoURL field. This field is optional. When left unspecified, the field is implicitly treated as if its value were "NewestFromBranch". + Accepted values: Lexical, NewestFromBranch, NewestTag, SemVer enum: - Lexical - NewestFromBranch @@ -306,6 +308,7 @@ spec: of the image specified by the RepoURL field. This field is optional. When left unspecified, the field is implicitly treated as if its value were "SemVer". + Accepted values: Digest, Lexical, NewestBuild, SemVer enum: - Digest - Lexical diff --git a/ui/src/gen/schema/warehouses.kargo.akuity.io_v1alpha1.json b/ui/src/gen/schema/warehouses.kargo.akuity.io_v1alpha1.json index 6ff454fb8..4a84f23d8 100644 --- a/ui/src/gen/schema/warehouses.kargo.akuity.io_v1alpha1.json +++ b/ui/src/gen/schema/warehouses.kargo.akuity.io_v1alpha1.json @@ -18,7 +18,7 @@ "properties": { "freightCreationPolicy": { "default": "Automatic", - "description": "FreightCreationPolicy describes how Freight is created by this Warehouse.\nThis field is optional. When left unspecified, the field is implicitly\ntreated as if its value were \"Automatic\".", + "description": "FreightCreationPolicy describes how Freight is created by this Warehouse.\nThis field is optional. When left unspecified, the field is implicitly\ntreated as if its value were \"Automatic\".\nAccepted values: Automatic, Manual", "enum": [ "Automatic", "Manual" @@ -86,7 +86,7 @@ }, "commitSelectionStrategy": { "default": "NewestFromBranch", - "description": "CommitSelectionStrategy specifies the rules for how to identify the newest\ncommit of interest in the repository specified by the RepoURL field. This\nfield is optional. When left unspecified, the field is implicitly treated\nas if its value were \"NewestFromBranch\".", + "description": "CommitSelectionStrategy specifies the rules for how to identify the newest\ncommit of interest in the repository specified by the RepoURL field. This\nfield is optional. When left unspecified, the field is implicitly treated\nas if its value were \"NewestFromBranch\".\nAccepted values: Lexical, NewestFromBranch, NewestTag, SemVer", "enum": [ "Lexical", "NewestFromBranch", @@ -179,7 +179,7 @@ }, "imageSelectionStrategy": { "default": "SemVer", - "description": "ImageSelectionStrategy specifies the rules for how to identify the newest version\nof the image specified by the RepoURL field. This field is optional. When\nleft unspecified, the field is implicitly treated as if its value were\n\"SemVer\".", + "description": "ImageSelectionStrategy specifies the rules for how to identify the newest version\nof the image specified by the RepoURL field. This field is optional. When\nleft unspecified, the field is implicitly treated as if its value were\n\"SemVer\".\nAccepted values: Digest, Lexical, NewestBuild, SemVer", "enum": [ "Digest", "Lexical", diff --git a/ui/src/gen/v1alpha1/generated_pb.ts b/ui/src/gen/v1alpha1/generated_pb.ts index 8c37c4552..90021c5f4 100644 --- a/ui/src/gen/v1alpha1/generated_pb.ts +++ b/ui/src/gen/v1alpha1/generated_pb.ts @@ -1558,6 +1558,7 @@ export class GitSubscription extends Message { * commit of interest in the repository specified by the RepoURL field. This * field is optional. When left unspecified, the field is implicitly treated * as if its value were "NewestFromBranch". + * Accepted values: Lexical, NewestFromBranch, NewestTag, SemVer * * +kubebuilder:default=NewestFromBranch * @@ -2035,6 +2036,7 @@ export class ImageSubscription extends Message { * of the image specified by the RepoURL field. This field is optional. When * left unspecified, the field is implicitly treated as if its value were * "SemVer". + * Accepted values: Digest, Lexical, NewestBuild, SemVer * * +kubebuilder:default=SemVer * @@ -3642,6 +3644,7 @@ export class WarehouseSpec extends Message { * FreightCreationPolicy describes how Freight is created by this Warehouse. * This field is optional. When left unspecified, the field is implicitly * treated as if its value were "Automatic". + * Accepted values: Automatic, Manual * * +kubebuilder:default=Automatic * +kubebuilder:validation:Optional