fix: configurable root credentials for dbinit + allow dbinit for external DB #5

Merged
sagar.patil merged 2 commits from fix/external-db-credentials-and-dbinit into main 2026-04-28 08:50:11 +00:00
2 changed files with 4 additions and 2 deletions
Showing only changes of commit 7a9c1db489 - Show all commits

View File

@ -50,12 +50,12 @@ spec:
- name: MYSQL_DATABASE - name: MYSQL_DATABASE
value: {{ include "hades.databaseName" . | quote }} value: {{ include "hades.databaseName" . | quote }}
- name: MYSQL_USER - name: MYSQL_USER
value: {{ include "hades.databaseUsername" . | quote }} value: {{ .Values.dbInit.mysqlUser | default "root" | quote }}
- name: MYSQL_PWD - name: MYSQL_PWD
valueFrom: valueFrom:
secretKeyRef: secretKeyRef:
name: {{ include "hades.databaseSecretName" . }} name: {{ include "hades.databaseSecretName" . }}
key: mysql-password key: {{ .Values.dbInit.mysqlPasswordKey | default "mysql-root-password" }}
command: command:
- /bin/bash - /bin/bash
- -c - -c

View File

@ -166,6 +166,8 @@ mysql:
# Automatically runs all SQL migration files from sql/ directory in alphabetical order # Automatically runs all SQL migration files from sql/ directory in alphabetical order
dbInit: dbInit:
enabled: true enabled: true
mysqlUser: "root"
mysqlPasswordKey: "mysql-root-password"
# ConfigMap for application configuration files # ConfigMap for application configuration files
config: config: