This is an automated email from the ASF dual-hosted git repository.

kerwin pushed a commit to branch 3.1.2-prepare
in repository https://gitbox.apache.org/repos/asf/dolphinscheduler.git


The following commit(s) were added to refs/heads/3.1.2-prepare by this push:
     new 5fe9b5c316 fix and enhance helm db config (#12707)
5fe9b5c316 is described below

commit 5fe9b5c3164062224cc2b0bf52364189d9b8fa3c
Author: 旺阳 <[email protected]>
AuthorDate: Sat Nov 5 18:20:03 2022 +0800

    fix and enhance helm db config (#12707)
---
 deploy/kubernetes/dolphinscheduler/templates/_helpers.tpl | 4 ++--
 deploy/kubernetes/dolphinscheduler/values.yaml            | 2 ++
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/deploy/kubernetes/dolphinscheduler/templates/_helpers.tpl 
b/deploy/kubernetes/dolphinscheduler/templates/_helpers.tpl
index a3eb2f37ba..0f36875d56 100644
--- a/deploy/kubernetes/dolphinscheduler/templates/_helpers.tpl
+++ b/deploy/kubernetes/dolphinscheduler/templates/_helpers.tpl
@@ -139,9 +139,9 @@ Create a database environment variables.
   {{- end }}
 - name: SPRING_DATASOURCE_URL
   {{- if .Values.postgresql.enabled }}
-  value: jdbc:postgresql://{{ template "dolphinscheduler.postgresql.fullname" 
. }}:5432/{{ .Values.postgresql.postgresqlDatabase }}?characterEncoding=utf8
+  value: jdbc:postgresql://{{ template "dolphinscheduler.postgresql.fullname" 
. }}:5432/{{ .Values.postgresql.postgresqlDatabase }}?{{ 
.Values.postgresql.params }}
   {{- else if .Values.mysql.enabled }}
-  value: jdbc:mysql://{{ template "dolphinscheduler.mysql.fullname" . 
}}:3306/{{ .Values.postgresql.postgresqlDatabase }}?characterEncoding=utf8
+  value: jdbc:mysql://{{ template "dolphinscheduler.mysql.fullname" . 
}}:3306/{{ .Values.mysql.auth.database }}?{{ .Values.mysql.auth.params }}
   {{- else }}
   value: jdbc:{{ .Values.externalDatabase.type }}://{{ 
.Values.externalDatabase.host }}:{{ .Values.externalDatabase.port }}/{{ 
.Values.externalDatabase.database }}?{{ .Values.externalDatabase.params }}
   {{- end }}
diff --git a/deploy/kubernetes/dolphinscheduler/values.yaml 
b/deploy/kubernetes/dolphinscheduler/values.yaml
index ac75029ab6..2f5184d4b8 100644
--- a/deploy/kubernetes/dolphinscheduler/values.yaml
+++ b/deploy/kubernetes/dolphinscheduler/values.yaml
@@ -38,6 +38,7 @@ postgresql:
   postgresqlUsername: "root"
   postgresqlPassword: "root"
   postgresqlDatabase: "dolphinscheduler"
+  params: "characterEncoding=utf8"
   persistence:
     enabled: false
     size: "20Gi"
@@ -49,6 +50,7 @@ mysql:
     username: "ds"
     password: "ds"
     database: "dolphinscheduler"
+    params: "characterEncoding=utf8"
   primary:
     persistence:
       enabled: false

Reply via email to