diff --git a/charts/cp-kafka-connect/templates/deployment.yaml b/charts/cp-kafka-connect/templates/deployment.yaml index 6a041ea9..738bd049 100644 --- a/charts/cp-kafka-connect/templates/deployment.yaml +++ b/charts/cp-kafka-connect/templates/deployment.yaml @@ -102,7 +102,7 @@ spec: - name: KAFKA_JMX_PORT value: "{{ .Values.jmx.port }}" {{- end }} - {{- if .Values.customEnv.CUSTOM_SCRIPT_PATH }} + {{- if .Values.customEnv.CUSTOM_SCRIPT_PATH }} command: - /bin/bash - -c @@ -110,11 +110,15 @@ spec: /etc/confluent/docker/run & $CUSTOM_SCRIPT_PATH sleep infinity + {{- end }} {{- if .Values.livenessProbe }} livenessProbe: +{{ toYaml .Values.readinessProbe | trim | indent 12 }} + {{- end }} + {{- if .Values.readinessProbe }} + livenessProbe: {{ toYaml .Values.livenessProbe | trim | indent 12 }} {{- end }} - {{- end }} {{- if .Values.volumeMounts }} volumeMounts: {{ toYaml .Values.volumeMounts | indent 10 }} diff --git a/charts/cp-kafka-connect/values.yaml b/charts/cp-kafka-connect/values.yaml index 131cd0bf..1c545745 100644 --- a/charts/cp-kafka-connect/values.yaml +++ b/charts/cp-kafka-connect/values.yaml @@ -122,6 +122,14 @@ secrets: ## and errors by the ENTRYPOINT are ignored by the container ## As an example such a similar script is added to "cp-helm-charts/examples/create-connectors.sh" ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ +readinessProbe: + # httpGet: + # path: /connectors + # port: 8083 + # initialDelaySeconds: 30 + # periodSeconds: 5 + # failureThreshold: 10 + livenessProbe: # httpGet: # path: /connectors