ChenYi015 commented on code in PR #4896: URL: https://github.com/apache/zeppelin/pull/4896#discussion_r1894543883
########## charts/zeppelin/templates/interpreter/spark/configmap.yaml: ########## @@ -0,0 +1,141 @@ +{{- /* +Licensed to the Apache Software Foundation (ASF) under one or more +contributor license agreements. See the NOTICE file distributed with +this work for additional information regarding copyright ownership. +The ASF licenses this file to You under the Apache License, Version 2.0 +(the "License"); you may not use this file except in compliance with +the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ -}} + +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ include "zeppelin.interpreter.spark.configMapName" . }} + namespace: {{ .Release.Namespace }} + labels: + {{- include "zeppelin.labels" . | nindent 4 }} +data: + spark-defaults.conf: | + # + # Licensed to the Apache Software Foundation (ASF) under one or more + # contributor license agreements. See the NOTICE file distributed with + # this work for additional information regarding copyright ownership. + # The ASF licenses this file to You under the Apache License, Version 2.0 + # (the "License"); you may not use this file except in compliance with + # the License. You may obtain a copy of the License at + # + # http://www.apache.org/licenses/LICENSE-2.0 + # + # Unless required by applicable law or agreed to in writing, software + # distributed under the License is distributed on an "AS IS" BASIS, + # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + # See the License for the specific language governing permissions and + # limitations under the License. + # + + # Default system properties included when running spark-submit. + # This is useful for setting default environmental settings. + + {{- range $key, $value := .Values.interpreter.spark.conf }} + {{ $key }} {{ $value }} + {{- end }} + + driver-pod-template.yaml: | + metadata: + {{- with .Values.interpreter.spark.labels }} + labels: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.interpreter.spark.annotations }} + annotations: + {{- toYaml . | nindent 8 }} + {{- end }} + spec: + containers: + - name: spark-kubernetes-driver + {{- with .Values.interpreter.spark.env }} + env: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.interpreter.spark.envFrom }} + envFrom: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.interpreter.spark.volumeMounts }} + volumeMounts: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.interpreter.spark.volumes }} + volumes: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.interpreter.nodeSelector }} + nodeSelector: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.interpreter.affinity }} + affinity: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.interpreter.tolerations }} + tolerations: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.interpreter.podSecurityContext }} + securityContext: + {{- toYaml . | nindent 8 }} + {{- end }} + + executor-pod-template.yaml: | Review Comment: Create the executor pod template file for that some fields of the executor pods (e.g. affinity, tolerations) cannot be configured using Spark configuration. Additionally, I believe it is more straightforward to configure the executor pods using a pod template rather than through Spark conf. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: reviews-unsubscr...@zeppelin.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org