|
|
@ -30,19 +30,19 @@ If release name contains chart name it will be used as a full name. |
|
|
|
Create default docker images' fullname. |
|
|
|
Create default docker images' fullname. |
|
|
|
*/}} |
|
|
|
*/}} |
|
|
|
{{- define "dolphinscheduler.image.fullname.master" -}} |
|
|
|
{{- define "dolphinscheduler.image.fullname.master" -}} |
|
|
|
{{- .Values.image.registry }}/dolphinscheduler-master:{{ .Values.image.tag | default .Chart.AppVersion -}} |
|
|
|
{{- .Values.image.registry }}/{{ .Values.image.master }}:{{ .Values.image.tag | default .Chart.AppVersion -}} |
|
|
|
{{- end -}} |
|
|
|
{{- end -}} |
|
|
|
{{- define "dolphinscheduler.image.fullname.worker" -}} |
|
|
|
{{- define "dolphinscheduler.image.fullname.worker" -}} |
|
|
|
{{- .Values.image.registry }}/dolphinscheduler-worker:{{ .Values.image.tag | default .Chart.AppVersion -}} |
|
|
|
{{- .Values.image.registry }}/{{ .Values.image.worker }}:{{ .Values.image.tag | default .Chart.AppVersion -}} |
|
|
|
{{- end -}} |
|
|
|
{{- end -}} |
|
|
|
{{- define "dolphinscheduler.image.fullname.api" -}} |
|
|
|
{{- define "dolphinscheduler.image.fullname.api" -}} |
|
|
|
{{- .Values.image.registry }}/dolphinscheduler-api:{{ .Values.image.tag | default .Chart.AppVersion -}} |
|
|
|
{{- .Values.image.registry }}/{{ .Values.image.api }}:{{ .Values.image.tag | default .Chart.AppVersion -}} |
|
|
|
{{- end -}} |
|
|
|
{{- end -}} |
|
|
|
{{- define "dolphinscheduler.image.fullname.alert" -}} |
|
|
|
{{- define "dolphinscheduler.image.fullname.alert" -}} |
|
|
|
{{- .Values.image.registry }}/dolphinscheduler-alert-server:{{ .Values.image.tag | default .Chart.AppVersion -}} |
|
|
|
{{- .Values.image.registry }}/{{ .Values.image.alert }}:{{ .Values.image.tag | default .Chart.AppVersion -}} |
|
|
|
{{- end -}} |
|
|
|
{{- end -}} |
|
|
|
{{- define "dolphinscheduler.image.fullname.tools" -}} |
|
|
|
{{- define "dolphinscheduler.image.fullname.tools" -}} |
|
|
|
{{- .Values.image.registry }}/dolphinscheduler-tools:{{ .Values.image.tag | default .Chart.AppVersion -}} |
|
|
|
{{- .Values.image.registry }}/{{ .Values.image.tools }}:{{ .Values.image.tag | default .Chart.AppVersion -}} |
|
|
|
{{- end -}} |
|
|
|
{{- end -}} |
|
|
|
|
|
|
|
|
|
|
|
{{/* |
|
|
|
{{/* |
|
|
@ -100,7 +100,16 @@ We truncate at 63 chars because some Kubernetes name fields are limited to this |
|
|
|
{{- end -}} |
|
|
|
{{- end -}} |
|
|
|
|
|
|
|
|
|
|
|
{{/* |
|
|
|
{{/* |
|
|
|
Create a default fully qualified zookkeeper name. |
|
|
|
Create a default fully qualified mysql name. |
|
|
|
|
|
|
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). |
|
|
|
|
|
|
|
*/}} |
|
|
|
|
|
|
|
{{- define "dolphinscheduler.mysql.fullname" -}} |
|
|
|
|
|
|
|
{{- $name := default "mysql" .Values.mysql.nameOverride -}} |
|
|
|
|
|
|
|
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}} |
|
|
|
|
|
|
|
{{- end -}} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
{{/* |
|
|
|
|
|
|
|
Create a default fully qualified zookeeper name. |
|
|
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). |
|
|
|
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). |
|
|
|
*/}} |
|
|
|
*/}} |
|
|
|
{{- define "dolphinscheduler.zookeeper.fullname" -}} |
|
|
|
{{- define "dolphinscheduler.zookeeper.fullname" -}} |
|
|
@ -123,18 +132,24 @@ Create a database environment variables. |
|
|
|
- name: DATABASE |
|
|
|
- name: DATABASE |
|
|
|
{{- if .Values.postgresql.enabled }} |
|
|
|
{{- if .Values.postgresql.enabled }} |
|
|
|
value: "postgresql" |
|
|
|
value: "postgresql" |
|
|
|
|
|
|
|
{{- else if .Values.mysql.enabled }} |
|
|
|
|
|
|
|
value: "mysql" |
|
|
|
{{- else }} |
|
|
|
{{- else }} |
|
|
|
value: {{ .Values.externalDatabase.type | quote }} |
|
|
|
value: {{ .Values.externalDatabase.type | quote }} |
|
|
|
{{- end }} |
|
|
|
{{- end }} |
|
|
|
- name: SPRING_DATASOURCE_URL |
|
|
|
- name: SPRING_DATASOURCE_URL |
|
|
|
{{- if .Values.postgresql.enabled }} |
|
|
|
{{- 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 }}?characterEncoding=utf8 |
|
|
|
|
|
|
|
{{- else if .Values.mysql.enabled }} |
|
|
|
|
|
|
|
value: jdbc:mysql://{{ template "dolphinscheduler.mysql.fullname" . }}:3306/{{ .Values.postgresql.postgresqlDatabase }}?characterEncoding=utf8 |
|
|
|
{{- else }} |
|
|
|
{{- else }} |
|
|
|
value: jdbc:{{ .Values.externalDatabase.type }}://{{ .Values.externalDatabase.host }}:{{ .Values.externalDatabase.port }}/{{ .Values.externalDatabase.database }}?{{ .Values.externalDatabase.params }} |
|
|
|
value: jdbc:{{ .Values.externalDatabase.type }}://{{ .Values.externalDatabase.host }}:{{ .Values.externalDatabase.port }}/{{ .Values.externalDatabase.database }}?{{ .Values.externalDatabase.params }} |
|
|
|
{{- end }} |
|
|
|
{{- end }} |
|
|
|
- name: SPRING_DATASOURCE_USERNAME |
|
|
|
- name: SPRING_DATASOURCE_USERNAME |
|
|
|
{{- if .Values.postgresql.enabled }} |
|
|
|
{{- if .Values.postgresql.enabled }} |
|
|
|
value: {{ .Values.postgresql.postgresqlUsername }} |
|
|
|
value: {{ .Values.postgresql.postgresqlUsername }} |
|
|
|
|
|
|
|
{{- else if .Values.mysql.enabled }} |
|
|
|
|
|
|
|
value: {{ .Values.mysql.auth.username }} |
|
|
|
{{- else }} |
|
|
|
{{- else }} |
|
|
|
value: {{ .Values.externalDatabase.username | quote }} |
|
|
|
value: {{ .Values.externalDatabase.username | quote }} |
|
|
|
{{- end }} |
|
|
|
{{- end }} |
|
|
@ -144,6 +159,9 @@ Create a database environment variables. |
|
|
|
{{- if .Values.postgresql.enabled }} |
|
|
|
{{- if .Values.postgresql.enabled }} |
|
|
|
name: {{ template "dolphinscheduler.postgresql.fullname" . }} |
|
|
|
name: {{ template "dolphinscheduler.postgresql.fullname" . }} |
|
|
|
key: postgresql-password |
|
|
|
key: postgresql-password |
|
|
|
|
|
|
|
{{- else if .Values.mysql.enabled }} |
|
|
|
|
|
|
|
name: {{ template "dolphinscheduler.mysql.fullname" . }} |
|
|
|
|
|
|
|
key: mysql-password |
|
|
|
{{- else }} |
|
|
|
{{- else }} |
|
|
|
name: {{ include "dolphinscheduler.fullname" . }}-externaldb |
|
|
|
name: {{ include "dolphinscheduler.fullname" . }}-externaldb |
|
|
|
key: database-password |
|
|
|
key: database-password |
|
|
@ -159,6 +177,8 @@ Wait for database to be ready. |
|
|
|
imagePullPolicy: IfNotPresent |
|
|
|
imagePullPolicy: IfNotPresent |
|
|
|
{{- if .Values.postgresql.enabled }} |
|
|
|
{{- if .Values.postgresql.enabled }} |
|
|
|
command: ['sh', '-xc', 'for i in $(seq 1 180); do nc -z -w3 {{ template "dolphinscheduler.postgresql.fullname" . }} 5432 && exit 0 || sleep 5; done; exit 1'] |
|
|
|
command: ['sh', '-xc', 'for i in $(seq 1 180); do nc -z -w3 {{ template "dolphinscheduler.postgresql.fullname" . }} 5432 && exit 0 || sleep 5; done; exit 1'] |
|
|
|
|
|
|
|
{{- else if .Values.mysql.enabled }} |
|
|
|
|
|
|
|
command: ['sh', '-xc', 'for i in $(seq 1 180); do nc -z -w3 {{ template "dolphinscheduler.mysql.fullname" . }} 3306 && exit 0 || sleep 5; done; exit 1'] |
|
|
|
{{- else }} |
|
|
|
{{- else }} |
|
|
|
command: ['sh', '-xc', 'for i in $(seq 1 180); do nc -z -w3 {{ .Values.externalDatabase.host }} {{ .Values.externalDatabase.port }} && exit 0 || sleep 5; done; exit 1'] |
|
|
|
command: ['sh', '-xc', 'for i in $(seq 1 180); do nc -z -w3 {{ .Values.externalDatabase.host }} {{ .Values.externalDatabase.port }} && exit 0 || sleep 5; done; exit 1'] |
|
|
|
{{- end }} |
|
|
|
{{- end }} |
|
|
|