Browse Source

[Improvement][Helm] support task type filter (#15179)

3.2.1-prepare
Gallardot 1 year ago committed by GitHub
parent
commit
2f2825784a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 10
      deploy/kubernetes/dolphinscheduler/templates/configmap.yaml
  2. 5
      deploy/kubernetes/dolphinscheduler/templates/deployment-dolphinscheduler-api.yaml
  3. 18
      deploy/kubernetes/dolphinscheduler/values.yaml
  4. 4
      docs/docs/en/guide/installation/kubernetes.md
  5. 4
      docs/docs/zh/guide/installation/kubernetes.md

10
deploy/kubernetes/dolphinscheduler/templates/configmap.yaml

@ -22,6 +22,16 @@ metadata:
app.kubernetes.io/name: {{ include "dolphinscheduler.fullname" . }}-common app.kubernetes.io/name: {{ include "dolphinscheduler.fullname" . }}-common
{{- include "dolphinscheduler.common.labels" . | nindent 4 }} {{- include "dolphinscheduler.common.labels" . | nindent 4 }}
data: data:
{{- if and .Values.api.taskTypeFilter.enabled }}
task-type-config.yaml: |-
{{- if .Values.api.taskTypeFilter.task }}
task:
{{- range $key, $value := .Values.api.taskTypeFilter.task }}
{{ $key }}:
{{- toYaml $value | nindent 8 }}
{{- end }}
{{- end }}
{{- end }}
common_properties: |- common_properties: |-
{{- if index .Values.conf "common" }} {{- if index .Values.conf "common" }}
{{- range $key, $value := index .Values.conf "common" }} {{- range $key, $value := index .Values.conf "common" }}

5
deploy/kubernetes/dolphinscheduler/templates/deployment-dolphinscheduler-api.yaml

@ -116,6 +116,11 @@ spec:
- name: config-volume - name: config-volume
mountPath: /opt/dolphinscheduler/conf/common.properties mountPath: /opt/dolphinscheduler/conf/common.properties
subPath: common_properties subPath: common_properties
{{- if .Values.api.taskTypeFilter.enabled }}
- name: config-volume
mountPath: /opt/dolphinscheduler/conf/task-type-config.yaml
subPath: task-type-config.yaml
{{- end }}
{{- include "dolphinscheduler.sharedStorage.volumeMount" . | nindent 12 }} {{- include "dolphinscheduler.sharedStorage.volumeMount" . | nindent 12 }}
{{- include "dolphinscheduler.fsFileResource.volumeMount" . | nindent 12 }} {{- include "dolphinscheduler.fsFileResource.volumeMount" . | nindent 12 }}
{{- include "dolphinscheduler.ldap.ssl.volumeMount" . | nindent 12 }} {{- include "dolphinscheduler.ldap.ssl.volumeMount" . | nindent 12 }}

18
deploy/kubernetes/dolphinscheduler/values.yaml

@ -692,6 +692,24 @@ api:
annotations: {} annotations: {}
env: env:
JAVA_OPTS: "-Xms512m -Xmx512m -Xmn256m" JAVA_OPTS: "-Xms512m -Xmx512m -Xmn256m"
taskTypeFilter:
# -- Enable or disable the task type filter
# -- If set to true, the API-Server will return tasks of a specific type set in api.taskTypeFilter.task
# -- Note: This feature only filters tasks to return a specific type on the WebUI. However, you can still create any task that DolphinScheduler supports via the API.
enabled: false
# -- @param taskTypeFilter.taskType task type
# -- ref: https://github.com/apache/dolphinscheduler/blob/dev/dolphinscheduler-api/src/main/resources/task-type-config.yaml
task: {}
# example task sets
# universal:
# - 'SQL'
# cloud: []
# logic: []
# dataIntegration: []
# dataQuality: []
# machineLearning: []
# other: []
ingress: ingress:
enabled: false enabled: false

4
docs/docs/en/guide/installation/kubernetes.md

@ -529,7 +529,7 @@ helm install dolphinscheduler-gpu-worker . \
## Appendix-Configuration ## Appendix-Configuration
| Parameter | Description | Default | | Parameter | Description | Default |
|----------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------| |----------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------|
| `timezone` | World time and date for cities in all time zones | `Asia/Shanghai` | | `timezone` | World time and date for cities in all time zones | `Asia/Shanghai` |
| <br/> | | | | <br/> | | |
| `image.repository` | Docker image repository for the DolphinScheduler | `apache/dolphinscheduler` | | `image.repository` | Docker image repository for the DolphinScheduler | `apache/dolphinscheduler` |
@ -775,6 +775,8 @@ helm install dolphinscheduler-gpu-worker . \
| `api.service.externalName` | `externalName` is the external reference that kubedns or equivalent will return as a CNAME record for this service | `nil` | | `api.service.externalName` | `externalName` is the external reference that kubedns or equivalent will return as a CNAME record for this service | `nil` |
| `api.service.loadBalancerIP` | `loadBalancerIP` when service.type is LoadBalancer. LoadBalancer will get created with the IP specified in this field | `nil` | | `api.service.loadBalancerIP` | `loadBalancerIP` when service.type is LoadBalancer. LoadBalancer will get created with the IP specified in this field | `nil` |
| `api.service.annotations` | `annotations` may need to be set when service.type is LoadBalancer | `{}` | | `api.service.annotations` | `annotations` may need to be set when service.type is LoadBalancer | `{}` |
| `api.taskTypeFilter.enabled` | Enable or disable the task type filter. If set to true, the API-Server will return tasks of a specific type set in api.taskTypeFilter.task.Note: This feature only filters tasks to return a specific type on the WebUI. However, you can still create any task that DolphinScheduler supports via the API. | `false` |
| `api.taskTypeFilter.task` | Task type ref: [task-type-config.yaml](https://github.com/apache/dolphinscheduler/blob/dev/dolphinscheduler-api/src/main/resources/task-type-config.yaml) | `{}` |
| <br/> | | | | <br/> | | |
| `ingress.enabled` | Enable ingress | `false` | | `ingress.enabled` | Enable ingress | `false` |
| `ingress.host` | Ingress host | `dolphinscheduler.org` | | `ingress.host` | Ingress host | `dolphinscheduler.org` |

4
docs/docs/zh/guide/installation/kubernetes.md

@ -528,7 +528,7 @@ helm install dolphinscheduler-gpu-worker . \
## 附录-配置 ## 附录-配置
| Parameter | Description | Default | | Parameter | Description | Default |
|----------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------| |----------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------|
| `timezone` | World time and date for cities in all time zones | `Asia/Shanghai` | | `timezone` | World time and date for cities in all time zones | `Asia/Shanghai` |
| <br/> | | | | <br/> | | |
| `image.repository` | Docker image repository for the DolphinScheduler | `apache/dolphinscheduler` | | `image.repository` | Docker image repository for the DolphinScheduler | `apache/dolphinscheduler` |
@ -774,6 +774,8 @@ helm install dolphinscheduler-gpu-worker . \
| `api.service.externalName` | `externalName` is the external reference that kubedns or equivalent will return as a CNAME record for this service | `nil` | | `api.service.externalName` | `externalName` is the external reference that kubedns or equivalent will return as a CNAME record for this service | `nil` |
| `api.service.loadBalancerIP` | `loadBalancerIP` when service.type is LoadBalancer. LoadBalancer will get created with the IP specified in this field | `nil` | | `api.service.loadBalancerIP` | `loadBalancerIP` when service.type is LoadBalancer. LoadBalancer will get created with the IP specified in this field | `nil` |
| `api.service.annotations` | `annotations` may need to be set when service.type is LoadBalancer | `{}` | | `api.service.annotations` | `annotations` may need to be set when service.type is LoadBalancer | `{}` |
| `api.taskTypeFilter.enabled` | Enable or disable the task type filter. If set to true, the API-Server will return tasks of a specific type set in api.taskTypeFilter.task.Note: This feature only filters tasks to return a specific type on the WebUI. However, you can still create any task that DolphinScheduler supports via the API. | `false` |
| `api.taskTypeFilter.task` | Task type ref: [task-type-config.yaml](https://github.com/apache/dolphinscheduler/blob/dev/dolphinscheduler-api/src/main/resources/task-type-config.yaml) | `{}` |
| <br/> | | | | <br/> | | |
| `ingress.enabled` | Enable ingress | `false` | | `ingress.enabled` | Enable ingress | `false` |
| `ingress.host` | Ingress host | `dolphinscheduler.org` | | `ingress.host` | Ingress host | `dolphinscheduler.org` |

Loading…
Cancel
Save