Skip to content

Commit 93d7d93

Browse files
varunrsekarshivamerla
authored andcommitted
fix stale nemo datastore CRDs
Signed-off-by: Varun Ramachandra Sekar <[email protected]>
1 parent 3bf1cb2 commit 93d7d93

File tree

4 files changed

+190
-84
lines changed

4 files changed

+190
-84
lines changed

api/apps/v1alpha1/nemo_datastore_types.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,9 +82,9 @@ type NemoDatastoreSpec struct {
8282

8383
// ObjectStore specifies the location and credentials for accessing the external Object Storage
8484
ObjectStoreConfig ObjectStoreConfig `json:"objectStoreConfig"` // e.g. minio
85-
// ExternalDatabase contains external PostgreSQL configuration
85+
// DatabaseConfig contains external PostgreSQL configuration
8686
DatabaseConfig DatabaseConfig `json:"databaseConfig"` // e.g. postgres
87-
// secrets contains the pre-requisite secrets that must be created before deploying the datastore CR
87+
// Secrets contains the pre-requisite secrets that must be created before deploying the datastore CR
8888
Secrets Secrets `json:"secrets"`
8989
// PVC defines the PersistentVolumeClaim for the datastore
9090
PVC *PersistentVolumeClaim `json:"pvc,omitempty"`

bundle/manifests/apps.nvidia.com_nemodatastores.yaml

Lines changed: 93 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,63 @@ spec:
6363
items:
6464
type: string
6565
type: array
66+
databaseConfig:
67+
description: DatabaseConfig contains external PostgreSQL configuration
68+
properties:
69+
credentials:
70+
description: |-
71+
DatabaseCredentials stores the configuration to retrieve the database credentials.
72+
Required, must not be nil.
73+
properties:
74+
passwordKey:
75+
default: password
76+
description: |-
77+
PasswordKey is the name of the key in the `CredentialsSecret` secret for the database credentials.
78+
Defaults to "password".
79+
type: string
80+
secretName:
81+
description: |-
82+
SecretName is the name of the secret which has the database credentials for a NEMO service user.
83+
Required, must not be empty.
84+
minLength: 1
85+
type: string
86+
user:
87+
description: |-
88+
User is the non-root username for a NEMO Service in the database.
89+
Required, must not be empty.
90+
minLength: 1
91+
type: string
92+
required:
93+
- secretName
94+
- user
95+
type: object
96+
databaseName:
97+
description: |-
98+
DatabaseName is the database name for a NEMO Service.
99+
Required, must not be empty.
100+
minLength: 1
101+
type: string
102+
host:
103+
description: |-
104+
Host is the hostname of the database.
105+
Required, must not be empty.
106+
minLength: 1
107+
type: string
108+
port:
109+
default: 5432
110+
description: |-
111+
Port is the port where the database is reachable at.
112+
If specified, this must be a valid port number, 0 < databasePort < 65536.
113+
Defaults to 5432.
114+
format: int32
115+
maximum: 65535
116+
minimum: 1
117+
type: integer
118+
required:
119+
- credentials
120+
- databaseName
121+
- host
122+
type: object
66123
env:
67124
items:
68125
description: EnvVar represents an environment variable present in
@@ -488,31 +545,6 @@ spec:
488545
- port
489546
type: object
490547
type: object
491-
externalDatabase:
492-
properties:
493-
database:
494-
type: string
495-
databaseSecret:
496-
type: string
497-
databaseSecretKey:
498-
type: string
499-
host:
500-
type: string
501-
port:
502-
type: integer
503-
sslMode:
504-
type: string
505-
user:
506-
type: string
507-
required:
508-
- database
509-
- databaseSecret
510-
- databaseSecretKey
511-
- host
512-
- port
513-
- sslMode
514-
- user
515-
type: object
516548
groupID:
517549
format: int64
518550
type: integer
@@ -732,32 +764,52 @@ spec:
732764
additionalProperties:
733765
type: string
734766
type: object
735-
objectStore:
767+
objectStoreConfig:
768+
description: ObjectStore specifies the location and credentials for
769+
accessing the external Object Storage
736770
properties:
737771
bucketName:
772+
description: BucketName is the bucket where LFS files will be
773+
stored
738774
type: string
775+
credentials:
776+
description: ObjectStoreCredentials stores the configuration to
777+
retrieve the object store credentials
778+
properties:
779+
passwordKey:
780+
description: PasswordKey is the name of the key in the `CredentialsSecret`
781+
secret for the object store credentials.
782+
type: string
783+
secretName:
784+
description: SecretName is the name of the secret which has
785+
the object credentials for a NEMO service user.
786+
type: string
787+
user:
788+
description: User is the non-root username for a NEMO Service
789+
in the object store.
790+
type: string
791+
required:
792+
- passwordKey
793+
- secretName
794+
- user
795+
type: object
739796
endpoint:
740-
type: string
741-
objectStoreSecret:
742-
type: string
743-
objectStoreSecretAccessKey:
744-
type: string
745-
objectStoreSecretAccessSecret:
797+
description: endpoint is the fully qualidfied object store endpoint
746798
type: string
747799
region:
800+
description: Region is the region where bucket is hosted
748801
type: string
749802
serveDirect:
803+
default: true
750804
type: boolean
751805
ssl:
806+
description: SSL enable ssl for object store transport
752807
type: boolean
753808
required:
754809
- bucketName
810+
- credentials
755811
- endpoint
756-
- objectStoreSecret
757-
- objectStoreSecretAccessKey
758-
- objectStoreSecretAccessSecret
759812
- region
760-
- serveDirect
761813
- ssl
762814
type: object
763815
podAffinity:
@@ -1117,8 +1169,7 @@ spec:
11171169
x-kubernetes-list-type: atomic
11181170
type: object
11191171
pvc:
1120-
description: PersistentVolumeClaim defines the attributes of PVC used
1121-
as a source for caching NIM model
1172+
description: PVC defines the PersistentVolumeClaim for the datastore
11221173
properties:
11231174
create:
11241175
description: Create indicates to create a new PVC
@@ -1973,6 +2024,8 @@ spec:
19732024
type: object
19742025
type: object
19752026
secrets:
2027+
description: Secrets contains the pre-requisite secrets that must
2028+
be created before deploying the datastore CR
19762029
properties:
19772030
datastoreConfigSecret:
19782031
type: string
@@ -2195,8 +2248,8 @@ spec:
21952248
type: integer
21962249
required:
21972250
- authSecret
2198-
- externalDatabase
2199-
- objectStore
2251+
- databaseConfig
2252+
- objectStoreConfig
22002253
- secrets
22012254
type: object
22022255
status:

config/crd/bases/apps.nvidia.com_nemodatastores.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ spec:
6464
type: string
6565
type: array
6666
databaseConfig:
67-
description: ExternalDatabase contains external PostgreSQL configuration
67+
description: DatabaseConfig contains external PostgreSQL configuration
6868
properties:
6969
credentials:
7070
description: |-
@@ -2024,7 +2024,7 @@ spec:
20242024
type: object
20252025
type: object
20262026
secrets:
2027-
description: secrets contains the pre-requisite secrets that must
2027+
description: Secrets contains the pre-requisite secrets that must
20282028
be created before deploying the datastore CR
20292029
properties:
20302030
datastoreConfigSecret:

0 commit comments

Comments
 (0)