feat(argo-cd): add poddisruptionbudget template. (#1110)

Signed-off-by: mugioka <okamugi0722@gmail.com>
pull/1107/head^2 argo-cd-3.33.0
mugi-o 2022-02-01 00:36:49 +09:00 committed by GitHub
parent 4c1ee93faf
commit f1995d697e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 202 additions and 2 deletions

View File

@ -2,7 +2,7 @@ apiVersion: v2
appVersion: v2.2.3
description: A Helm chart for ArgoCD, a declarative, GitOps continuous delivery tool for Kubernetes.
name: argo-cd
version: 3.32.1
version: 3.33.0
home: https://github.com/argoproj/argo-helm
icon: https://argo-cd.readthedocs.io/en/stable/assets/logo.png
keywords:
@ -21,4 +21,4 @@ dependencies:
condition: redis-ha.enabled
annotations:
artifacthub.io/changes: |
- "[Fixed]: Add custom volume as Helm working dir (sync with upstream manifests)"
- "[Added]: PodDisruptionBudget template"

View File

@ -279,6 +279,9 @@ NAME: my-release
| controller.metrics.serviceMonitor.selector | object | `{}` | Prometheus ServiceMonitor selector |
| controller.name | string | `"application-controller"` | Application controller name string |
| controller.nodeSelector | object | `{}` | [Node selector] |
| controller.pdb.annotations | object | `{}` | Annotations to be added to application controller pdb |
| controller.pdb.enabled | bool | `false` | Deploy a Poddisruptionbudget for the application controller |
| controller.pdb.labels | object | `{}` | Labels to be added to application controller pdb |
| controller.podAnnotations | object | `{}` | Annotations to be added to application controller pods |
| controller.podLabels | object | `{}` | Labels to be added to application controller pods |
| controller.priorityClassName | string | `""` | Priority class for the application controller pods |
@ -346,6 +349,9 @@ NAME: my-release
| repoServer.metrics.serviceMonitor.selector | object | `{}` | Prometheus ServiceMonitor selector |
| repoServer.name | string | `"repo-server"` | Repo server name |
| repoServer.nodeSelector | object | `{}` | [Node selector] |
| repoServer.pdb.annotations | object | `{}` | Annotations to be added to Repo server pdb |
| repoServer.pdb.enabled | bool | `false` | Deploy a Poddisruptionbudget for the Repo server |
| repoServer.pdb.labels | object | `{}` | Labels to be added to Repo server pdb |
| repoServer.podAnnotations | object | `{}` | Annotations to be added to repo server pods |
| repoServer.podLabels | object | `{}` | Labels to be added to repo server pods |
| repoServer.priorityClassName | string | `""` | Priority class for the repo server |
@ -456,6 +462,9 @@ NAME: my-release
| server.metrics.serviceMonitor.selector | object | `{}` | Prometheus ServiceMonitor selector |
| server.name | string | `"server"` | Argo CD server name |
| server.nodeSelector | object | `{}` | [Node selector] |
| server.pdb.annotations | object | `{}` | Annotations to be added to server pdb |
| server.pdb.enabled | bool | `false` | Deploy a Poddisruptionbudget for the server |
| server.pdb.labels | object | `{}` | Labels to be added to server pdb |
| server.podAnnotations | object | `{}` | Annotations to be added to server pods |
| server.podLabels | object | `{}` | Labels to be added to server pods |
| server.priorityClassName | string | `""` | Priority class for the Argo CD server |
@ -539,6 +548,9 @@ NAME: my-release
| dex.metrics.serviceMonitor.selector | object | `{}` | Prometheus ServiceMonitor selector |
| dex.name | string | `"dex-server"` | Dex name |
| dex.nodeSelector | object | `{}` | [Node selector] |
| dex.pdb.annotations | object | `{}` | Annotations to be added to Dex server pdb |
| dex.pdb.enabled | bool | `false` | Deploy a Poddisruptionbudget for the Dex server |
| dex.pdb.labels | object | `{}` | Labels to be added to Dex server pdb |
| dex.podAnnotations | object | `{}` | Annotations to be added to the Dex server pods |
| dex.podLabels | object | `{}` | Labels to be added to the Dex server pods |
| dex.priorityClassName | string | `""` | Priority class for dex |
@ -600,6 +612,9 @@ NAME: my-release
| redis.metrics.serviceMonitor.selector | object | `{}` | Prometheus ServiceMonitor selector |
| redis.name | string | `"redis"` | Redis name |
| redis.nodeSelector | object | `{}` | [Node selector] |
| redis.pdb.annotations | object | `{}` | Annotations to be added to Redis server pdb |
| redis.pdb.enabled | bool | `false` | Deploy a Poddisruptionbudget for the Redis server |
| redis.pdb.labels | object | `{}` | Labels to be added to Redis server pdb |
| redis.podAnnotations | object | `{}` | Annotations to be added to the Redis server pods |
| redis.podLabels | object | `{}` | Labels to be added to the Redis server pods |
| redis.priorityClassName | string | `""` | Priority class for redis |

View File

@ -0,0 +1,26 @@
{{- if .Values.controller.pdb.enabled }}
apiVersion: policy/v1beta1
kind: PodDisruptionBudget
metadata:
name: {{ template "argo-cd.controller.fullname" . }}
labels:
{{- include "argo-cd.labels" (dict "context" . "component" .Values.controller.name "name" .Values.controller.name) | 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-cd.selectorLabels" (dict "context" . "name" .Values.controller.name) | nindent 6 }}
{{- end }}

View File

@ -0,0 +1,26 @@
{{- if .Values.repoServer.pdb.enabled }}
apiVersion: policy/v1beta1
kind: PodDisruptionBudget
metadata:
name: {{ template "argo-cd.repoServer.fullname" . }}
labels:
{{- include "argo-cd.labels" (dict "context" . "component" .Values.repoServer.name "name" .Values.repoServer.name) | nindent 4 }}
{{- with .Values.repoServer.pdb.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.repoServer.pdb.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
{{- if .Values.repoServer.pdb.minAvailable }}
minAvailable: {{ .Values.repoServer.pdb.minAvailable }}
{{- else if .Values.repoServer.pdb.maxUnavailable }}
maxUnavailable: {{ .Values.repoServer.pdb.maxUnavailable }}
{{- else }}
minAvailable: 0
{{- end }}
selector:
matchLabels:
{{- include "argo-cd.selectorLabels" (dict "context" . "name" .Values.repoServer.name) | nindent 6 }}
{{- end }}

View File

@ -0,0 +1,26 @@
{{- if .Values.server.pdb.enabled }}
apiVersion: policy/v1beta1
kind: PodDisruptionBudget
metadata:
name: {{ template "argo-cd.server.fullname" . }}
labels:
{{- include "argo-cd.labels" (dict "context" . "component" .Values.server.name "name" .Values.server.name) | nindent 4 }}
{{- with .Values.server.pdb.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.server.pdb.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
{{- if .Values.server.pdb.minAvailable }}
minAvailable: {{ .Values.server.pdb.minAvailable }}
{{- else if .Values.server.pdb.maxUnavailable }}
maxUnavailable: {{ .Values.server.pdb.maxUnavailable }}
{{- else }}
minAvailable: 0
{{- end }}
selector:
matchLabels:
{{- include "argo-cd.selectorLabels" (dict "context" . "name" .Values.server.name) | nindent 6 }}
{{- end }}

View File

@ -0,0 +1,26 @@
{{- if .Values.dex.pdb.enabled }}
apiVersion: policy/v1beta1
kind: PodDisruptionBudget
metadata:
name: {{ template "argo-cd.dex.fullname" . }}
labels:
{{- include "argo-cd.labels" (dict "context" . "component" .Values.dex.name "name" .Values.dex.name) | nindent 4 }}
{{- with .Values.dex.pdb.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.dex.pdb.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
{{- if .Values.dex.pdb.minAvailable }}
minAvailable: {{ .Values.dex.pdb.minAvailable }}
{{- else if .Values.dex.pdb.maxUnavailable }}
maxUnavailable: {{ .Values.dex.pdb.maxUnavailable }}
{{- else }}
minAvailable: 0
{{- end }}
selector:
matchLabels:
{{- include "argo-cd.selectorLabels" (dict "context" . "name" .Values.dex.name) | nindent 6 }}
{{- end }}

View File

@ -0,0 +1,26 @@
{{- if .Values.redis.pdb.enabled }}
apiVersion: policy/v1beta1
kind: PodDisruptionBudget
metadata:
name: {{ template "argo-cd.redis.fullname" . }}
labels:
{{- include "argo-cd.labels" (dict "context" . "component" .Values.redis.name "name" .Values.redis.name) | nindent 4 }}
{{- with .Values.redis.pdb.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.redis.pdb.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
{{- if .Values.redis.pdb.minAvailable }}
minAvailable: {{ .Values.redis.pdb.minAvailable }}
{{- else if .Values.redis.pdb.maxUnavailable }}
maxUnavailable: {{ .Values.redis.pdb.maxUnavailable }}
{{- else }}
minAvailable: 0
{{- end }}
selector:
matchLabels:
app.kubernetes.io/name: {{ include "argo-cd.name" . }}-{{ .Values.redis.name }}
{{- end }}

View File

@ -345,6 +345,17 @@ controller:
# name: custom-tools
# subPath: helm
pdb:
# -- Labels to be added to application controller pdb
labels: {}
# -- Annotations to be added to application controller pdb
annotations: {}
# -- Deploy a Poddisruptionbudget for the application controller
enabled: false
# minAvailable: 1
# maxUnavailable: 0
## Dex
dex:
# -- Enable dex
@ -539,6 +550,17 @@ dex:
# name: custom-tools
# subPath: helm
pdb:
# -- Labels to be added to Dex server pdb
labels: {}
# -- Annotations to be added to Dex server pdb
annotations: {}
# -- Deploy a Poddisruptionbudget for the Dex server
enabled: false
# minAvailable: 1
# maxUnavailable: 0
## Redis
redis:
# -- Enable redis
@ -712,6 +734,17 @@ redis:
# -- Prometheus ServiceMonitor labels
additionalLabels: {}
pdb:
# -- Labels to be added to Redis server pdb
labels: {}
# -- Annotations to be added to Redis server pdb
annotations: {}
# -- Deploy a Poddisruptionbudget for the Redis server
enabled: false
# minAvailable: 1
# maxUnavailable: 0
# This key configures Redis-HA subchart and when enabled (redis-ha.enabled=true)
# the custom redis deployment is omitted
# Check the redis-ha chart for more properties
@ -1352,6 +1385,17 @@ server:
# - name: argo-rollouts
# url: https://github.com/argoproj-labs/rollout-extension/releases/download/v0.1.0/extension.tar
pdb:
# -- Labels to be added to server pdb
labels: {}
# -- Annotations to be added to server pdb
annotations: {}
# -- Deploy a Poddisruptionbudget for the server
enabled: false
# minAvailable: 1
# maxUnavailable: 0
## Repo Server
repoServer:
# -- Repo server name
@ -1590,6 +1634,17 @@ repoServer:
# name: custom-tools
# subPath: helm
pdb:
# -- Labels to be added to Repo server pdb
labels: {}
# -- Annotations to be added to Repo server pdb
annotations: {}
# -- Deploy a Poddisruptionbudget for the Repo server
enabled: false
# minAvailable: 1
# maxUnavailable: 0
## Argo Configs
configs:
# -- Provide one or multiple [external cluster credentials]