Skip to content

Commit

Permalink
Merge pull request #128 from clementguillot/127-cant-set-custom-db-na…
Browse files Browse the repository at this point in the history
…me-when-using-helm-chart

feat(helm-chart): add `server.database.dbName` to override default server's Mongo DB name
  • Loading branch information
clementguillot authored Apr 23, 2024
2 parents 1f42209 + c757af0 commit e851933
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion apps/helm-chart/src/templates/server/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ spec:
- name: QUARKUS_MONGODB_CONNECTION_STRING
{{- include "nx-cloud-ce.server.database.connection-string" . | nindent 12 }}
- name: QUARKUS_MONGODB_DATABASE
value: {{ .Values.server.name }}
value: {{ default .Values.server.name .Values.server.database.dbName }}
{{- with .Values.server.envFrom }}
envFrom:
{{- toYaml . | nindent 10 }}
Expand Down
2 changes: 2 additions & 0 deletions apps/helm-chart/src/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,8 @@ server:

# -- DB configuration when using external MongoDB
database:
# @default -- `""` (defaults to server.name=server)
dbName: ""
# @default -- `""` (defaults to mongodb.enabled=true)
connectionStringSecretName: ""
# @default -- `""` (defaults to mongodb.enabled=true)
Expand Down

0 comments on commit e851933

Please sign in to comment.