Add chart flink cdc session cluster chart
This commit is contained in:
@@ -0,0 +1,80 @@
|
||||
{{- if .Values.job.enabled }}
|
||||
apiVersion: batch/v1
|
||||
kind: Job
|
||||
metadata:
|
||||
name: {{ .Values.job.name }}
|
||||
namespace: {{ .Release.Namespace }}
|
||||
labels:
|
||||
{{- include "flink-cdc-session.labels" . | nindent 4 }}
|
||||
spec:
|
||||
backoffLimit: 0
|
||||
template:
|
||||
spec:
|
||||
serviceAccountName: {{ .Values.serviceAccount }}
|
||||
containers:
|
||||
- name: submit
|
||||
image: {{ .Values.image.repository }}:{{ .Values.image.tag }}
|
||||
{{- if eq .Values.checkpointStorage.storageType "gcs" }}
|
||||
env:
|
||||
- name: GOOGLE_APPLICATION_CREDENTIALS
|
||||
value: {{ .Values.checkpointStorage.gcs.credentialPath }}
|
||||
{{- else if eq .Values.checkpointStorage.storageType "s3" }}
|
||||
{{- if or .Values.checkpointStorage.s3.existingSecret .Values.checkpointStorage.s3.accessKeyId }}
|
||||
env:
|
||||
{{- if .Values.checkpointStorage.s3.existingSecret }}
|
||||
- name: AWS_ACCESS_KEY_ID
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ .Values.checkpointStorage.s3.existingSecret }}
|
||||
key: {{ .Values.checkpointStorage.s3.accessKeyIdKey }}
|
||||
- name: AWS_SECRET_ACCESS_KEY
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: {{ .Values.checkpointStorage.s3.existingSecret }}
|
||||
key: {{ .Values.checkpointStorage.s3.secretAccessKeyKey }}
|
||||
{{- else }}
|
||||
- name: AWS_ACCESS_KEY_ID
|
||||
value: {{ .Values.checkpointStorage.s3.accessKeyId }}
|
||||
- name: AWS_SECRET_ACCESS_KEY
|
||||
value: {{ .Values.checkpointStorage.s3.secretAccessKey }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
command: ["/bin/sh", "-c"]
|
||||
args:
|
||||
- |
|
||||
cd /opt/flink/flink-cdc-3.5.0
|
||||
./bin/flink-cdc.sh \
|
||||
{{ .Values.job.pipelineFile }} \
|
||||
-Dexecution.checkpointing.interval={{ .Values.pipeline.checkpointInterval }} \
|
||||
-Drest.address={{ .Values.job.restAddress }} \
|
||||
-Drest.port={{ .Values.job.restPort }}
|
||||
volumeMounts:
|
||||
- name: pipeline-config
|
||||
mountPath: /opt/flink/flink-cdc-3.5.0/conf
|
||||
{{- if .Values.truststore.enabled }}
|
||||
- name: truststore
|
||||
mountPath: /opt/flink/certs
|
||||
readOnly: true
|
||||
{{- end }}
|
||||
{{- if eq .Values.checkpointStorage.storageType "gcs" }}
|
||||
- name: gcs-key
|
||||
mountPath: /opt/flink/gcs-key
|
||||
readOnly: true
|
||||
{{- end }}
|
||||
volumes:
|
||||
- name: pipeline-config
|
||||
configMap:
|
||||
name: cdc-pipeline-config
|
||||
{{- if .Values.truststore.enabled }}
|
||||
- name: truststore
|
||||
secret:
|
||||
secretName: {{ .Values.truststore.secretName }}
|
||||
{{- end }}
|
||||
{{- if eq .Values.checkpointStorage.storageType "gcs" }}
|
||||
- name: gcs-key
|
||||
secret:
|
||||
secretName: {{ .Values.checkpointStorage.gcs.credentialSecret }}
|
||||
{{- end }}
|
||||
restartPolicy: Never
|
||||
{{- end }}
|
||||
Reference in New Issue
Block a user