diff --git a/hades/templates/job-dbinit.yaml b/hades/templates/job-dbinit.yaml index 0c8f584..4d4ad5d 100644 --- a/hades/templates/job-dbinit.yaml +++ b/hades/templates/job-dbinit.yaml @@ -50,12 +50,12 @@ spec: - name: MYSQL_DATABASE value: {{ include "hades.databaseName" . | quote }} - name: MYSQL_USER - value: {{ include "hades.databaseUsername" . | quote }} + value: {{ .Values.dbInit.mysqlUser | default "root" | quote }} - name: MYSQL_PWD valueFrom: secretKeyRef: name: {{ include "hades.databaseSecretName" . }} - key: mysql-password + key: {{ .Values.dbInit.mysqlPasswordKey | default "mysql-root-password" }} command: - /bin/bash - -c diff --git a/hades/values.yaml b/hades/values.yaml index 138bdc3..74a03d8 100644 --- a/hades/values.yaml +++ b/hades/values.yaml @@ -166,6 +166,8 @@ mysql: # Automatically runs all SQL migration files from sql/ directory in alphabetical order dbInit: enabled: true + mysqlUser: "root" + mysqlPasswordKey: "mysql-root-password" # ConfigMap for application configuration files config: