[bitnami/metallb] Use custom probes if given (#12525)

Without this change, in order to use a custom probe, the user has to
specify the probe parameters, and also must specify for the original
probe "enabled: false".

Issue: #12354
Signed-off-by: Orgad Shaneh <orgad.shaneh@audiocodes.com>

Signed-off-by: Orgad Shaneh <orgad.shaneh@audiocodes.com>
This commit is contained in:
Orgad Shaneh
2022-09-21 10:29:42 +00:00
committed by GitHub
parent 51261895fa
commit fd91af7f18
3 changed files with 19 additions and 19 deletions
+1 -1
View File
@@ -30,4 +30,4 @@ sources:
- https://github.com/metallb/metallb
- https://github.com/bitnami/containers/tree/main/bitnami/metallb
- https://metallb.universe.tf
version: 4.1.2
version: 4.1.3
@@ -127,28 +127,28 @@ spec:
{{- include "common.tplvalues.render" (dict "value" .Values.controller.extraVolumeMounts "context" $) | nindent 12 }}
{{- end }}
{{- if not .Values.diagnosticMode.enabled }}
{{- if .Values.controller.livenessProbe.enabled }}
{{- if .Values.controller.customLivenessProbe }}
livenessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.controller.customLivenessProbe "context" $) | nindent 12 }}
{{- else if .Values.controller.livenessProbe.enabled }}
livenessProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.controller.livenessProbe "enabled") "context" $) | nindent 12 }}
httpGet:
path: /metrics
port: metrics
{{- else if .Values.controller.customLivenessProbe }}
livenessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.controller.customLivenessProbe "context" $) | nindent 12 }}
{{- end }}
{{- if .Values.controller.readinessProbe.enabled }}
{{- if .Values.controller.customReadinessProbe }}
readinessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.controller.customReadinessProbe "context" $) | nindent 12 }}
{{- else if .Values.controller.readinessProbe.enabled }}
readinessProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.controller.readinessProbe "enabled") "context" $) | nindent 12 }}
httpGet:
path: /metrics
port: metrics
{{- else if .Values.controller.customReadinessProbe }}
readinessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.controller.customReadinessProbe "context" $) | nindent 12 }}
{{- end }}
{{- if .Values.controller.startupProbe.enabled }}
{{- if .Values.controller.customStartupProbe }}
startupProbe: {{- include "common.tplvalues.render" (dict "value" .Values.controller.customStartupProbe "context" $) | nindent 12 }}
{{- else if .Values.controller.startupProbe.enabled }}
startupProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.controller.startupProbe "enabled") "context" $) | nindent 12 }}
tcpSocket:
port: metrics
{{- else if .Values.controller.customStartupProbe }}
startupProbe: {{- include "common.tplvalues.render" (dict "value" .Values.controller.customStartupProbe "context" $) | nindent 12 }}
{{- end }}
{{- end }}
{{- if .Values.controller.resources }}
@@ -126,28 +126,28 @@ spec:
- name: metrics
containerPort: {{ .Values.speaker.containerPorts.metrics }}
{{- if not .Values.diagnosticMode.enabled }}
{{- if .Values.speaker.livenessProbe.enabled }}
{{- if .Values.speaker.customLivenessProbe }}
livenessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.speaker.customLivenessProbe "context" $) | nindent 12 }}
{{- else if .Values.speaker.livenessProbe.enabled }}
livenessProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.speaker.livenessProbe "enabled") "context" $) | nindent 12 }}
httpGet:
path: /metrics
port: metrics
{{- else if .Values.speaker.customLivenessProbe }}
livenessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.speaker.customLivenessProbe "context" $) | nindent 12 }}
{{- end }}
{{- if .Values.speaker.readinessProbe.enabled }}
{{- if .Values.speaker.customReadinessProbe }}
readinessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.speaker.customReadinessProbe "context" $) | nindent 12 }}
{{- else if .Values.speaker.readinessProbe.enabled }}
readinessProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.speaker.readinessProbe "enabled") "context" $) | nindent 12 }}
httpGet:
path: /metrics
port: metrics
{{- else if .Values.speaker.customReadinessProbe }}
readinessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.speaker.customReadinessProbe "context" $) | nindent 12 }}
{{- end }}
{{- if .Values.speaker.startupProbe.enabled }}
{{- if .Values.speaker.customStartupProbe }}
startupProbe: {{- include "common.tplvalues.render" (dict "value" .Values.speaker.customStartupProbe "context" $) | nindent 12 }}
{{- else if .Values.speaker.startupProbe.enabled }}
startupProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.speaker.startupProbe "enabled") "context" $) | nindent 12 }}
tcpSocket:
port: metrics
{{- else if .Values.speaker.customStartupProbe }}
startupProbe: {{- include "common.tplvalues.render" (dict "value" .Values.speaker.customStartupProbe "context" $) | nindent 12 }}
{{- end }}
{{- end }}
{{- if .Values.speaker.resources }}