Make rolling update strategies configurable for web and worker deployments in Helm templates (#522)

Co-authored-by: Josh Waldrep <joshua.waldrep5+github@gmail.com>
This commit is contained in:
LPW
2025-12-30 16:10:47 -05:00
committed by GitHub
parent 4e87eead2c
commit f48e020fc2
2 changed files with 18 additions and 3 deletions

View File

@@ -10,8 +10,13 @@ spec:
strategy:
type: RollingUpdate
rollingUpdate:
maxUnavailable: 0
maxSurge: 25%
{{- if and .Values.web.strategy .Values.web.strategy.rollingUpdate }}
maxUnavailable: {{ .Values.web.strategy.rollingUpdate.maxUnavailable | default 1 }}
maxSurge: {{ .Values.web.strategy.rollingUpdate.maxSurge | default 0 }}
{{- else }}
maxUnavailable: 1
maxSurge: 0
{{- end }}
selector:
matchLabels:
app.kubernetes.io/component: web

View File

@@ -6,7 +6,17 @@ metadata:
{{- include "sure.labels" . | nindent 4 }}
spec:
replicas: {{ .Values.worker.replicas }}
revisionHistoryLimit: 2
revisionHistoryLimit: {{ .Values.worker.revisionHistoryLimit | default 2 }}
strategy:
type: RollingUpdate
rollingUpdate:
{{- if and .Values.worker.strategy .Values.worker.strategy.rollingUpdate }}
maxUnavailable: {{ .Values.worker.strategy.rollingUpdate.maxUnavailable | default 1 }}
maxSurge: {{ .Values.worker.strategy.rollingUpdate.maxSurge | default 0 }}
{{- else }}
maxUnavailable: 1
maxSurge: 0
{{- end }}
selector:
matchLabels:
app.kubernetes.io/component: worker