fix(deployment): add missing rolling release strategy
All checks were successful
Generate README / generate-parameters (push) Successful in 28s
Helm / helm-lint (push) Successful in 16s
Helm / helm-unittest (push) Successful in 18s
Markdown linter / markdown-link-checker (push) Successful in 30s
Markdown linter / markdown-lint (push) Successful in 26s
Release / publish-chart (push) Successful in 20s

This commit is contained in:
Markus Pesch 2025-01-19 21:45:16 +01:00
parent b29f79370c
commit fb218484d0
Signed by: volker.raschek
GPG Key ID: 852BCC170D81A982
4 changed files with 13 additions and 2 deletions

View File

@ -248,7 +248,7 @@ deployment:
| `deployment.replicas` | Number of replicas for the postgres-exporter deployment. | `1` | | `deployment.replicas` | Number of replicas for the postgres-exporter deployment. | `1` |
| `deployment.restartPolicy` | Restart policy of the postgres-exporter deployment. | `""` | | `deployment.restartPolicy` | Restart policy of the postgres-exporter deployment. | `""` |
| `deployment.securityContext` | Security context of the postgres-exporter deployment. | `{}` | | `deployment.securityContext` | Security context of the postgres-exporter deployment. | `{}` |
| `deployment.strategy.type` | Strategy type - `Recreate` or `Rollingupdate`. | `Recreate` | | `deployment.strategy.type` | Strategy type - `Recreate` or `Rollingupdate`. | `Rollingupdate` |
| `deployment.strategy.rollingUpdate.maxSurge` | The maximum number of pods that can be scheduled above the desired number of pods during a rolling update. | `1` | | `deployment.strategy.rollingUpdate.maxSurge` | The maximum number of pods that can be scheduled above the desired number of pods during a rolling update. | `1` |
| `deployment.strategy.rollingUpdate.maxUnavailable` | The maximum number of pods that can be unavailable during a rolling update. | `1` | | `deployment.strategy.rollingUpdate.maxUnavailable` | The maximum number of pods that can be unavailable during a rolling update. | `1` |
| `deployment.terminationGracePeriodSeconds` | How long to wait until forcefully kill the pod. | `60` | | `deployment.terminationGracePeriodSeconds` | How long to wait until forcefully kill the pod. | `60` |

View File

@ -126,3 +126,7 @@ spec:
volumes: volumes:
{{- toYaml $volumes.volumes | nindent 6 }} {{- toYaml $volumes.volumes | nindent 6 }}
{{- end }} {{- end }}
{{- with .Values.deployment.strategy }}
strategy:
{{- toYaml . | nindent 4 }}
{{- end }}

View File

@ -95,6 +95,13 @@ tests:
path: spec.template.spec.tolerations path: spec.template.spec.tolerations
- notExists: - notExists:
path: spec.template.spec.topologySpreadConstraints path: spec.template.spec.topologySpreadConstraints
- equal:
path: spec.strategy
value:
type: "Rollingupdate"
rollingUpdate:
maxSurge: 1
maxUnavailable: 1
- it: Test custom replicas - it: Test custom replicas
set: set:

View File

@ -228,7 +228,7 @@ deployment:
## @param deployment.strategy.rollingUpdate.maxSurge The maximum number of pods that can be scheduled above the desired number of pods during a rolling update. ## @param deployment.strategy.rollingUpdate.maxSurge The maximum number of pods that can be scheduled above the desired number of pods during a rolling update.
## @param deployment.strategy.rollingUpdate.maxUnavailable The maximum number of pods that can be unavailable during a rolling update. ## @param deployment.strategy.rollingUpdate.maxUnavailable The maximum number of pods that can be unavailable during a rolling update.
strategy: strategy:
type: "Recreate" type: "Rollingupdate"
rollingUpdate: rollingUpdate:
maxSurge: 1 maxSurge: 1
maxUnavailable: 1 maxUnavailable: 1