Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[bitnami/redis] Fix sentinel PDB condition #27080

Merged
merged 7 commits into from
Jun 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions bitnami/redis/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
# Changelog

## 19.5.2 (2024-06-06)
## 19.5.3 (2024-06-12)

* [bitnami/redis] Release 19.5.2 ([#27012](https://github.com/bitnami/charts/pull/27012))
* [bitnami/redis] Fix sentinel PDB condition ([#27080](https://github.com/bitnami/charts/pull/27080))

## <small>19.5.2 (2024-06-06)</small>

* [bitnami/redis] Release 19.5.2 (#27012) ([128a592](https://github.com/bitnami/charts/commit/128a59210d13d4619c9c80aa0631897f0d981917)), closes [#27012](https://github.com/bitnami/charts/issues/27012)

## <small>19.5.1 (2024-06-04)</small>

Expand Down
2 changes: 1 addition & 1 deletion bitnami/redis/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,4 @@ maintainers:
name: redis
sources:
- https://github.com/bitnami/charts/tree/main/bitnami/redis
version: 19.5.2
version: 19.5.3
12 changes: 6 additions & 6 deletions bitnami/redis/templates/master/pdb.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
Copyright Broadcom, Inc. All Rights Reserved.
SPDX-License-Identifier: APACHE-2.0
*/}}

{{- if and .Values.master.pdb.create (gt (int64 .Values.master.count) 0) (or (eq .Values.architecture "replication") (not .Values.sentinel.enabled)) }}
{{- $pdb := coalesce .Values.pdb .Values.master.pdb }}
juan131 marked this conversation as resolved.
Show resolved Hide resolved
{{- if and $pdb.create (gt (int64 .Values.master.count) 0) (or (not (eq .Values.architecture "replication")) (not .Values.sentinel.enabled)) }}
apiVersion: {{ include "common.capabilities.policy.apiVersion" . }}
kind: PodDisruptionBudget
metadata:
Expand All @@ -15,11 +15,11 @@ metadata:
annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }}
{{- end }}
spec:
{{- if .Values.master.pdb.minAvailable }}
minAvailable: {{ .Values.master.pdb.minAvailable }}
{{- if $pdb.minAvailable }}
minAvailable: {{ $pdb.minAvailable }}
{{- end }}
{{- if or .Values.master.pdb.maxUnavailable (not .Values.master.pdb.minAvailable)}}
maxUnavailable: {{ .Values.master.pdb.maxUnavailable | default 1 }}
{{- if or $pdb.maxUnavailable (not $pdb.minAvailable)}}
maxUnavailable: {{ $pdb.maxUnavailable | default 1 }}
{{- end }}
selector:
matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 6 }}
Expand Down
2 changes: 1 addition & 1 deletion bitnami/redis/templates/replicas/pdb.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Copyright Broadcom, Inc. All Rights Reserved.
SPDX-License-Identifier: APACHE-2.0
*/}}

{{- $pdb := coalesce .Values.replica.pdb .Values.pdb }}
{{- $pdb := coalesce .Values.pdb .Values.replica.pdb }}
{{- if and (eq .Values.architecture "replication") (not .Values.sentinel.enabled) $pdb.create }}
apiVersion: {{ include "common.capabilities.policy.apiVersion" . }}
kind: PodDisruptionBudget
Expand Down
12 changes: 6 additions & 6 deletions bitnami/redis/templates/sentinel/pdb.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
Copyright Broadcom, Inc. All Rights Reserved.
SPDX-License-Identifier: APACHE-2.0
*/}}

{{- if and (eq .Values.architecture "replication") (not .Values.sentinel.enabled) .Values.replica.pdb.create }}
{{- $pdb := coalesce .Values.pdb .Values.replica.pdb }}
{{- if and (eq .Values.architecture "replication") .Values.sentinel.enabled $pdb.create }}
apiVersion: {{ include "common.capabilities.policy.apiVersion" . }}
kind: PodDisruptionBudget
metadata:
Expand All @@ -15,11 +15,11 @@ metadata:
annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }}
{{- end }}
spec:
{{- if .Values.replica.pdb.minAvailable }}
minAvailable: {{ .Values.replica.pdb.minAvailable }}
{{- if $pdb.minAvailable }}
minAvailable: {{ $pdb.minAvailable }}
{{- end }}
{{- if or .Values.replica.pdb.maxUnavailable (not .Values.replica.pdb.minAvailable) }}
maxUnavailable: {{ .Values.replica.pdb.maxUnavailable | default 1 }}
{{- if or $pdb.maxUnavailable (not $pdb.minAvailable) }}
maxUnavailable: {{ $pdb.maxUnavailable | default 1 }}
{{- end }}
selector:
matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 6 }}
Expand Down
Loading