Skip to content

Commit

Permalink
feat: [nmrxiv-app]-replace postgresql
Browse files Browse the repository at this point in the history
with rdkitcatridge
  • Loading branch information
NishaSharma14 committed Nov 10, 2023
1 parent 1b5ccb8 commit 77c1ab8
Show file tree
Hide file tree
Showing 4 changed files with 59 additions and 35 deletions.
11 changes: 6 additions & 5 deletions charts/nmrxiv-app/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 0.6.2
version: 0.6.3

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
Expand All @@ -27,10 +27,10 @@ version: 0.6.2
appVersion: "1.16.0"

dependencies:
- name: postgresql
- name: postgresql # to be removed - deprecated and replaced by rdkitpostgres
version: "11.6.14"
repository: "https://charts.bitnami.com/bitnami"
condition: database.enabled
condition: postgresql.enabled
- name: redis
version: "17.6.0"
repository: https://charts.bitnami.com/bitnami
Expand All @@ -43,9 +43,10 @@ dependencies:
version: "0.1.44"
repository: https://nfdi4chem.github.io/repo-helm-charts
condition: meilisearch.enabled
- name: pythonmicroservice
- name: nmrium
version: "0.1.0"
repository: https://nfdi4chem.github.io/repo-helm-charts
- name: nmrium
- name: rdkitcatridgepostgres
version: "0.1.0"
repository: https://nfdi4chem.github.io/repo-helm-charts
condition: rdkitcatridgepostgres.enabled
17 changes: 12 additions & 5 deletions charts/nmrxiv-app/templates/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,18 @@ data:
LOG_LEVEL: {{ .Values.logProperties.logLevel }}

#DB Properties
DB_USERNAME: {{ required "A valid Values.postgresql.auth.username entry required!" .Values.postgresql.auth.username }}
DB_CONNECTION: {{ required "A valid .Values.postgresql.connection entry required!" .Values.postgresql.connection }}
DB_HOST: {{ printf "%s-postgresql" .Release.Name | quote }}
DB_PORT: {{ .Values.postgresql.port | default 5432 | quote }}
DB_DATABASE: {{ required "A valid Values.postgresql.auth.database entry required!" .Values.postgresql.auth.database }}
# DB_USERNAME: {{ required "A valid Values.postgresql.auth.username entry required!" .Values.postgresql.auth.username }}
# DB_CONNECTION: {{ required "A valid .Values.postgresql.connection entry required!" .Values.postgresql.connection }}
# DB_HOST: {{ printf "%s-postgresql" .Release.Name | quote }}
# DB_PORT: {{ .Values.postgresql.port | default 5432 | quote }}
# DB_DATABASE: {{ required "A valid Values.postgresql.auth.database entry required!" .Values.postgresql.auth.database }}

#DB Properties
DB_USERNAME: {{ required "A valid .Values.rdkitcatridgepostgres.auth.user entry required!" .Values.rdkitcatridgepostgres.auth.user }}
DB_CONNECTION: {{ required "A valid .Values.rdkitcatridgepostgres.connection entry required!" .Values.rdkitcatridgepostgres.connection }}
DB_HOST: {{ printf "%s-rdkitcatridgepostgres" .Release.Name | quote }}
DB_PORT: {{ .Values.rdkitcatridgepostgres.port | default 5432 | quote }}
DB_DATABASE: {{ required "A valid .Values.rdkitcatridgepostgres.auth.db entry required!" .Values.rdkitcatridgepostgres.auth.db }}

#File Storage Properties
{{ if .Values.fileStorage.enabled }}
Expand Down
13 changes: 9 additions & 4 deletions charts/nmrxiv-app/templates/secret.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,15 @@ data:
{{- end -}}

#DB Secrets
{{- if .Values.postgresql.enabled }}
DB_PASSWORD: {{ required "A valid .Values.postgresql.auth.password entry required!" .Values.postgresql.auth.password |b64enc | quote }}
{{- else if .Values.mysql.enabled }}
DB_PASSWORD: {{ required "A valid .Values.postgresql.auth.password entry required!" .Values.postgresql.auth.password |b64enc | quote }}
# {{- if .Values.postgresql.enabled }}
# DB_PASSWORD: {{ required "A valid .Values.postgresql.auth.password entry required!" .Values.postgresql.auth.password |b64enc | quote }}
# {{- else if .Values.mysql.enabled }}
# DB_PASSWORD: {{ required "A valid .Values.postgresql.auth.password entry required!" .Values.postgresql.auth.password |b64enc | quote }}
# {{- end -}}

#DB Secrets
{{- if .Values.rdkitcatridgepostgres.enabled }}
DB_PASSWORD: {{ required "A valid .Values.rdkitcatridgepostgres.auth.pgPassword entry required!" .Values.rdkitcatridgepostgres.auth.pgPassword |b64enc | quote }}
{{- end -}}

#File Storage Secrets
Expand Down
53 changes: 32 additions & 21 deletions charts/nmrxiv-app/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -157,30 +157,41 @@ mail:
# mailer: smtp

# DB properties
postgresql:
# postgresql:
# enabled: true
# # global:
# # storageClass: standard
# connection: pgsql
# primary:
# persistence:
# enabled: false
# existingClaim: ''
# size: 1Gi
# # host: nmrxiv-postgresql
# # port: 5432
# auth:
# username: pguser
# password: secret
# database: nmrxiv
# postgresPassword: secret
# resources:
# limits:
# cpu: 200m
# memory: 150Mi
# requests:
# cpu: 20m
# memory: 100Mi

#DB Properties
rdkitcatridgepostgres:
enabled: true
# global:
# storageClass: standard
connection: pgsql
primary:
persistence:
enabled: false
existingClaim: ''
size: 1Gi
# host: nmrxiv-postgresql
# port: 5432
auth:
username: pguser
password: secret
database: nmrxiv
pgPassword: secret
db: test
user: test
postgresPassword: secret
resources:
limits:
cpu: 200m
memory: 150Mi
requests:
cpu: 20m
memory: 100Mi
connection: pgsql
port: 5432

fileStorage:
# Below values are for file storage configuration.
Expand Down

0 comments on commit 77c1ab8

Please sign in to comment.