typokign / matrix-chart

Helm chart for deploying a Matrix homeserver stack
MIT License
88 stars 47 forks source link

Discord bridge SQLite Database uses a PVC, but deployment is not configured to stop the old pods when scheduling a new one. #34

Closed Routhinator closed 4 years ago

Routhinator commented 4 years ago

Now that I have enabled the discord bridge, deploying updates is failing as this is a stateful deployment (due to the SQLite PVC) that requires the old pod to be killed before the new one can be scheduled.

Two ways to solve this that I know of, use a statefulset instead of a deployment, or define the updateStrategy and specify a maxsurge of 0..

Recreate may also work.

I'll put in a PR this evening unless you beat me to it.

Routhinator commented 4 years ago

Scratch recreate - I just recalled that if you have 3 pods, recreate will take them all down at once. updateStrategy with maxSurge 0 and maxUnavailable 1 is the best approach as this will do a rolling update - 1 by 1.