Skip to content

Commit 45a0cf0

Browse files
vmayrink1Vinicius Mayrink
andauthored
feat(chart): add support for startup, liveness and readiness probes (#187)
Co-authored-by: Vinicius Mayrink <vinicius.mayrink@hotmail.com>
1 parent 5cd8a8d commit 45a0cf0

2 files changed

Lines changed: 23 additions & 0 deletions

File tree

chart/templates/deployment.yaml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,18 @@ spec:
5050
securityContext:
5151
{{- toYaml .Values.securityContext | nindent 10 }}
5252
imagePullPolicy: {{ .Values.image.pullPolicy }}
53+
{{- with .Values.startupProbe }}
54+
startupProbe:
55+
{{- toYaml . | nindent 12 }}
56+
{{- end }}
57+
{{- with .Values.livenessProbe }}
58+
livenessProbe:
59+
{{- toYaml . | nindent 12 }}
60+
{{- end }}
61+
{{- with .Values.readinessProbe }}
62+
readinessProbe:
63+
{{- toYaml . | nindent 12 }}
64+
{{- end }}
5365
{{- with .Values.imagePullSecrets }}
5466
imagePullSecrets:
5567
{{- toYaml . | nindent 8 }}

chart/values.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,17 @@ securityContext:
4949
capabilities:
5050
drop:
5151
- ALL
52+
# Optional health probes for the controller container.
53+
# Note: this controller doesn't serve HTTP traffic by default, so exec probes are usually the best option.
54+
# Example:
55+
# livenessProbe:
56+
# exec:
57+
# command: ["/bin/sh", "-c", "ps aux | grep -v grep | grep -q kube-downscaler"]
58+
# initialDelaySeconds: 30
59+
# periodSeconds: 10
60+
startupProbe: {}
61+
livenessProbe: {}
62+
readinessProbe: {}
5263

5364
resources:
5465
limits:

0 commit comments

Comments
 (0)