FEAT(repo): add startupProbe for CPU-limited apps
- Add startupProbe to Helm chart template - Configure 300s startup timeout (10s × 30 attempts) - Set initialDelaySeconds to 0 for liveness/readiness - Prevents pod restart loop during slow startup
This commit is contained in:
@@ -60,6 +60,14 @@ spec:
|
||||
port: {{ .Values.containerPort }}
|
||||
initialDelaySeconds: {{ .Values.healthCheck.readinessProbe.initialDelaySeconds }}
|
||||
periodSeconds: {{ .Values.healthCheck.readinessProbe.periodSeconds }}
|
||||
{{- if .Values.healthCheck.startupProbe }}
|
||||
startupProbe:
|
||||
httpGet:
|
||||
path: {{ .Values.healthCheck.path }}
|
||||
port: {{ .Values.containerPort }}
|
||||
periodSeconds: {{ .Values.healthCheck.startupProbe.periodSeconds | default 10 }}
|
||||
failureThreshold: {{ .Values.healthCheck.startupProbe.failureThreshold | default 30 }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
restartPolicy: Always
|
||||
{{- with .Values.nodeSelector }}
|
||||
|
||||
@@ -45,11 +45,14 @@ resources:
|
||||
healthCheck:
|
||||
enabled: true
|
||||
path: /
|
||||
startupProbe:
|
||||
periodSeconds: 10
|
||||
failureThreshold: 30
|
||||
livenessProbe:
|
||||
initialDelaySeconds: 30
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 10
|
||||
readinessProbe:
|
||||
initialDelaySeconds: 5
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 5
|
||||
|
||||
envFrom:
|
||||
|
||||
@@ -45,11 +45,14 @@ resources:
|
||||
healthCheck:
|
||||
enabled: true
|
||||
path: /
|
||||
startupProbe:
|
||||
periodSeconds: 10
|
||||
failureThreshold: 30
|
||||
livenessProbe:
|
||||
initialDelaySeconds: 30
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 10
|
||||
readinessProbe:
|
||||
initialDelaySeconds: 5
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 5
|
||||
|
||||
envFrom:
|
||||
|
||||
@@ -45,11 +45,14 @@ resources:
|
||||
healthCheck:
|
||||
enabled: true
|
||||
path: /
|
||||
startupProbe:
|
||||
periodSeconds: 10
|
||||
failureThreshold: 30
|
||||
livenessProbe:
|
||||
initialDelaySeconds: 10
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 10
|
||||
readinessProbe:
|
||||
initialDelaySeconds: 5
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 5
|
||||
|
||||
externalSecret:
|
||||
|
||||
@@ -45,11 +45,14 @@ resources:
|
||||
healthCheck:
|
||||
enabled: true
|
||||
path: /
|
||||
startupProbe:
|
||||
periodSeconds: 10
|
||||
failureThreshold: 30
|
||||
livenessProbe:
|
||||
initialDelaySeconds: 10
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 10
|
||||
readinessProbe:
|
||||
initialDelaySeconds: 5
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 5
|
||||
|
||||
externalSecret:
|
||||
|
||||
@@ -50,11 +50,14 @@ resources:
|
||||
healthCheck:
|
||||
enabled: true
|
||||
path: /api/health
|
||||
startupProbe:
|
||||
periodSeconds: 10
|
||||
failureThreshold: 30
|
||||
livenessProbe:
|
||||
initialDelaySeconds: 30
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 10
|
||||
readinessProbe:
|
||||
initialDelaySeconds: 5
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 5
|
||||
|
||||
env:
|
||||
|
||||
@@ -47,11 +47,14 @@ resources:
|
||||
healthCheck:
|
||||
enabled: true
|
||||
path: /
|
||||
startupProbe:
|
||||
periodSeconds: 10
|
||||
failureThreshold: 30
|
||||
livenessProbe:
|
||||
initialDelaySeconds: 30
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 10
|
||||
readinessProbe:
|
||||
initialDelaySeconds: 5
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 5
|
||||
|
||||
env:
|
||||
|
||||
@@ -49,11 +49,14 @@ resources:
|
||||
healthCheck:
|
||||
enabled: true
|
||||
path: /
|
||||
startupProbe:
|
||||
periodSeconds: 10
|
||||
failureThreshold: 30
|
||||
livenessProbe:
|
||||
initialDelaySeconds: 30
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 10
|
||||
readinessProbe:
|
||||
initialDelaySeconds: 5
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 5
|
||||
|
||||
env:
|
||||
|
||||
@@ -50,11 +50,14 @@ resources:
|
||||
healthCheck:
|
||||
enabled: true
|
||||
path: /api/health
|
||||
startupProbe:
|
||||
periodSeconds: 10
|
||||
failureThreshold: 30
|
||||
livenessProbe:
|
||||
initialDelaySeconds: 30
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 10
|
||||
readinessProbe:
|
||||
initialDelaySeconds: 5
|
||||
initialDelaySeconds: 0
|
||||
periodSeconds: 5
|
||||
|
||||
env:
|
||||
|
||||
Reference in New Issue
Block a user