Skip to content

Commit d934ae5

Browse files
committed
Move the configmap for postgres init to template
1 parent e70fb14 commit d934ae5

File tree

3 files changed

+25
-15
lines changed

3 files changed

+25
-15
lines changed

charts/custom-values.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ host: &commonHost msbi.ipb-halle.de
44
pathPrefix: &commonPathPrefix MassBank3
55
# release name of the helm install of massbank3-frontend, required for dbtool
66
# to identify the hostname of the postgres database
7-
massbank3ReleaseName: mymassbank
7+
massbank3ReleaseName: massbank
88

99
# postgres settings
1010
# the password for the postgres admin user
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
apiVersion: v1
2+
kind: ConfigMap
3+
metadata:
4+
name: postgres-config
5+
labels:
6+
{{- include "massbank3-server.labels" . | nindent 4 }}
7+
data:
8+
000_bingo_install.sql: |
9+
\c {{ .Values.postgresql.auth.database }}
10+
\i /opt/bingo-postgres/init-scripts/000_bingo_install.sql
11+
00_init.sql: |
12+
-- update ALLOW_NON_UNIQUE_DEAROMATIZATION to 1 --
13+
UPDATE bingo.bingo_config SET cvalue = 1 WHERE cname = 'ALLOW_NON_UNIQUE_DEAROMATIZATION';
14+
GRANT ALL PRIVILEGES ON SCHEMA bingo TO "{{ .Values.postgresql.auth.username }}";

charts/massbank3-server/values.yaml

Lines changed: 10 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ global:
1717
postgresql:
1818
image:
1919
tag: "15"
20+
debug: true
2021
auth:
2122
postgresPassword: "massbank3adminpassword"
2223
username: "massbank3"
@@ -26,12 +27,7 @@ postgresql:
2627
initdb:
2728
user: "postgres"
2829
password: "massbank3adminpassword"
29-
scripts:
30-
000_bingo_install.sql: |
31-
\i /opt/bingo-postgres/init-scripts/000_bingo_install.sql
32-
00_init.sql: |
33-
-- update ALLOW_NON_UNIQUE_DEAROMATIZATION to 1 --
34-
UPDATE bingo.bingo_config SET cvalue = 1 WHERE cname = 'ALLOW_NON_UNIQUE_DEAROMATIZATION';
30+
scriptsConfigMap: "postgres-config"
3531
initContainers:
3632
- name: bingo-init
3733
image: quay.io/massbank/postgres-bingo-init:v15-bingo-1.28.0
@@ -134,14 +130,14 @@ resources:
134130
# memory: 128Mi
135131

136132
# This is to setup the liveness and readiness probes more information can be found here: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/
137-
livenessProbe:
138-
httpGet:
139-
path: /version
140-
port: http
141-
readinessProbe:
142-
httpGet:
143-
path: /version
144-
port: http
133+
#livenessProbe:
134+
# httpGet:
135+
# path: /version
136+
# port: http
137+
#readinessProbe:
138+
# httpGet:
139+
# path: /version
140+
# port: http
145141

146142
# This section is for setting up autoscaling more information can be found here: https://kubernetes.io/docs/concepts/workloads/autoscaling/
147143
autoscaling:

0 commit comments

Comments
 (0)