1
0
Fork 0
mirror of https://github.com/plankanban/planka.git synced 2025-08-05 21:45:30 +02:00

feat: Change the update strategy in case of persistence

In case planka is installed with a PV associated to the planka pod, to
persist attachments and avatars for example, the default update strategy
for the deployment will fail. The default "rolling update" strategy
would indeed try to start a new pod before stopping the old one. But as
the old pod is attached to the PV, the new pod will fail to attach and
so will stay in "container creating" mode, and the old pod will never be
stopped.

To avoid that, adding a condition on the deployment to use the
"recreate" update strategy if the persistence is enabled. This will
ensure the old pod is stopped and so detached from the PV before trying
to attach the new one.
This commit is contained in:
Aline Fauquette 2024-09-13 14:46:59 +02:00
parent 8fd0f682d9
commit 76de5f3593

View file

@ -11,6 +11,10 @@ spec:
selector:
matchLabels:
{{- include "planka.selectorLabels" . | nindent 6 }}
{{- if .Values.persistence.enabled }}
strategy:
type: Recreate
{{- end }}
template:
metadata:
{{- with .Values.podAnnotations }}