Skip to content

Commit

Permalink
chore: add validation rules to the versioneddataset field
Browse files Browse the repository at this point in the history
  • Loading branch information
0xff-dev committed Dec 18, 2023
1 parent 62ea64b commit 3413d74
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions api/base/v1alpha1/versioneddataset_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ type VersionedDatasetSpec struct {
Dataset *TypedObjectReference `json:"dataset"`

// Version
// +kubebuilder:validation:Pattern=^v\d+$
Version string `json:"version"`

// FileGroups included in this `VersionedDataset`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ spec:
type: integer
version:
description: Version
pattern: ^v\d+$
type: string
required:
- dataset
Expand Down
2 changes: 1 addition & 1 deletion deploy/charts/arcadia/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
name: arcadia
description: A Helm chart(KubeBB Component) for KubeAGI Arcadia
type: application
version: 0.1.43
version: 0.1.44
appVersion: "0.0.1"

keywords:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ spec:
type: integer
version:
description: Version
pattern: ^v\d+$
type: string
required:
- dataset
Expand Down

0 comments on commit 3413d74

Please sign in to comment.