feat(argo-rollouts): Add PDB option to controller and dashboard (#1294)
* feat(argo-rollouts): Add PodDisruptionBudget option to controller and dashboard Signed-off-by: Ward Loos <ward.loos@gmail.com> * Apply changes from code review Signed-off-by: Marco Kilchhofer <mkilchhofer@users.noreply.github.com> Co-authored-by: Ward Loos <ward.loos@aaqua.live> Co-authored-by: Marco Kilchhofer <mkilchhofer@users.noreply.github.com>
This commit is contained in:
parent
0956363ebb
commit
dc4f6919d1
7 changed files with 106 additions and 3 deletions
|
|
@ -0,0 +1,27 @@
|
|||
{{- if .Values.controller.pdb.enabled }}
|
||||
apiVersion: {{ include "argo-rollouts.podDisruptionBudget.apiVersion" . }}
|
||||
kind: PodDisruptionBudget
|
||||
metadata:
|
||||
name: {{ template "argo-rollouts.fullname" . }}
|
||||
labels:
|
||||
{{- include "argo-rollouts.labels" . | nindent 4 }}
|
||||
{{- with .Values.controller.pdb.labels }}
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
{{- with .Values.controller.pdb.annotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- if .Values.controller.pdb.minAvailable }}
|
||||
minAvailable: {{ .Values.controller.pdb.minAvailable }}
|
||||
{{- else if .Values.controller.pdb.maxUnavailable }}
|
||||
maxUnavailable: {{ .Values.controller.pdb.maxUnavailable }}
|
||||
{{- else }}
|
||||
minAvailable: 0
|
||||
{{- end }}
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "argo-rollouts.selectorLabels" . | nindent 6 }}
|
||||
app.kubernetes.io/component: {{ .Values.controller.component }}
|
||||
{{- end }}
|
||||
Loading…
Add table
Add a link
Reference in a new issue