chore(argo-cd): Remove support for autoscaling/v1 (#2237)
Signed-off-by: Petr Drastil <petr.drastil@gmail.com>
This commit is contained in:
parent
6797f01c1b
commit
224a227fa4
7 changed files with 35 additions and 65 deletions
|
@ -3,7 +3,7 @@ appVersion: v2.8.2
|
||||||
kubeVersion: ">=1.23.0-0"
|
kubeVersion: ">=1.23.0-0"
|
||||||
description: A Helm chart for Argo CD, a declarative, GitOps continuous delivery tool for Kubernetes.
|
description: A Helm chart for Argo CD, a declarative, GitOps continuous delivery tool for Kubernetes.
|
||||||
name: argo-cd
|
name: argo-cd
|
||||||
version: 5.44.0
|
version: 5.45.0
|
||||||
home: https://github.com/argoproj/argo-helm
|
home: https://github.com/argoproj/argo-helm
|
||||||
icon: https://argo-cd.readthedocs.io/en/stable/assets/logo.png
|
icon: https://argo-cd.readthedocs.io/en/stable/assets/logo.png
|
||||||
sources:
|
sources:
|
||||||
|
@ -27,4 +27,6 @@ annotations:
|
||||||
url: https://argoproj.github.io/argo-helm/pgp_keys.asc
|
url: https://argoproj.github.io/argo-helm/pgp_keys.asc
|
||||||
artifacthub.io/changes: |
|
artifacthub.io/changes: |
|
||||||
- kind: removed
|
- kind: removed
|
||||||
description: Support for cert-manager APIs prior K8s 1.22
|
description: Option apiVersionOverrides.autoscaling as v2 is now GA
|
||||||
|
- kind: removed
|
||||||
|
description: Codebase for autoscaling/v1 API
|
||||||
|
|
|
@ -383,7 +383,6 @@ NAME: my-release
|
||||||
|
|
||||||
| Key | Type | Default | Description |
|
| Key | Type | Default | Description |
|
||||||
|-----|------|---------|-------------|
|
|-----|------|---------|-------------|
|
||||||
| apiVersionOverrides.autoscaling | string | `""` | String to override apiVersion of autoscaling rendered by this helm chart |
|
|
||||||
| apiVersionOverrides.cloudgoogle | string | `""` | String to override apiVersion of GKE resources rendered by this helm chart |
|
| apiVersionOverrides.cloudgoogle | string | `""` | String to override apiVersion of GKE resources rendered by this helm chart |
|
||||||
| crds.additionalLabels | object | `{}` | Addtional labels to be added to all CRDs |
|
| crds.additionalLabels | object | `{}` | Addtional labels to be added to all CRDs |
|
||||||
| crds.annotations | object | `{}` | Annotations to be added to all CRDs |
|
| crds.annotations | object | `{}` | Annotations to be added to all CRDs |
|
||||||
|
@ -572,7 +571,7 @@ NAME: my-release
|
||||||
| Key | Type | Default | Description |
|
| Key | Type | Default | Description |
|
||||||
|-----|------|---------|-------------|
|
|-----|------|---------|-------------|
|
||||||
| repoServer.affinity | object | `{}` (defaults to global.affinity preset) | Assign custom [affinity] rules to the deployment |
|
| repoServer.affinity | object | `{}` (defaults to global.affinity preset) | Assign custom [affinity] rules to the deployment |
|
||||||
| repoServer.autoscaling.behavior | object | `{}` | Configures the scaling behavior of the target in both Up and Down directions. This is only available on HPA apiVersion `autoscaling/v2beta2` and newer |
|
| repoServer.autoscaling.behavior | object | `{}` | Configures the scaling behavior of the target in both Up and Down directions. |
|
||||||
| repoServer.autoscaling.enabled | bool | `false` | Enable Horizontal Pod Autoscaler ([HPA]) for the repo server |
|
| repoServer.autoscaling.enabled | bool | `false` | Enable Horizontal Pod Autoscaler ([HPA]) for the repo server |
|
||||||
| repoServer.autoscaling.maxReplicas | int | `5` | Maximum number of replicas for the repo server [HPA] |
|
| repoServer.autoscaling.maxReplicas | int | `5` | Maximum number of replicas for the repo server [HPA] |
|
||||||
| repoServer.autoscaling.metrics | list | `[]` | Configures custom HPA metrics for the Argo CD repo server Ref: https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/ |
|
| repoServer.autoscaling.metrics | list | `[]` | Configures custom HPA metrics for the Argo CD repo server Ref: https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/ |
|
||||||
|
@ -670,7 +669,7 @@ NAME: my-release
|
||||||
| server.GKEmanagedCertificate.domains | list | `["argocd.example.com"]` | Domains for the Google Managed Certificate |
|
| server.GKEmanagedCertificate.domains | list | `["argocd.example.com"]` | Domains for the Google Managed Certificate |
|
||||||
| server.GKEmanagedCertificate.enabled | bool | `false` | Enable ManagedCertificate custom resource for Google Kubernetes Engine. |
|
| server.GKEmanagedCertificate.enabled | bool | `false` | Enable ManagedCertificate custom resource for Google Kubernetes Engine. |
|
||||||
| server.affinity | object | `{}` (defaults to global.affinity preset) | Assign custom [affinity] rules to the deployment |
|
| server.affinity | object | `{}` (defaults to global.affinity preset) | Assign custom [affinity] rules to the deployment |
|
||||||
| server.autoscaling.behavior | object | `{}` | Configures the scaling behavior of the target in both Up and Down directions. This is only available on HPA apiVersion `autoscaling/v2beta2` and newer |
|
| server.autoscaling.behavior | object | `{}` | Configures the scaling behavior of the target in both Up and Down directions. |
|
||||||
| server.autoscaling.enabled | bool | `false` | Enable Horizontal Pod Autoscaler ([HPA]) for the Argo CD server |
|
| server.autoscaling.enabled | bool | `false` | Enable Horizontal Pod Autoscaler ([HPA]) for the Argo CD server |
|
||||||
| server.autoscaling.maxReplicas | int | `5` | Maximum number of replicas for the Argo CD server [HPA] |
|
| server.autoscaling.maxReplicas | int | `5` | Maximum number of replicas for the Argo CD server [HPA] |
|
||||||
| server.autoscaling.metrics | list | `[]` | Configures custom HPA metrics for the Argo CD server Ref: https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/ |
|
| server.autoscaling.metrics | list | `[]` | Configures custom HPA metrics for the Argo CD server Ref: https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/ |
|
||||||
|
|
|
@ -121,6 +121,9 @@ REMOVED option redis.containerPort - Use redis.containerPorts
|
||||||
{{- if .Values.redis.metrics.containerPort }}
|
{{- if .Values.redis.metrics.containerPort }}
|
||||||
REMOVED option redis.metrics.containerPort - Use redis.containerPorts
|
REMOVED option redis.metrics.containerPort - Use redis.containerPorts
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
{{- if .Values.apiVersionOverrides.autoscaling }}
|
||||||
|
REMOVED option apiVersionOverrides.autoscaling - API autoscaling/v2 is GA from 1.23
|
||||||
|
{{- end }}
|
||||||
{{- if .Values.apiVersionOverrides.certmanager }}
|
{{- if .Values.apiVersionOverrides.certmanager }}
|
||||||
REMOVED option apiVersionOverrides.certmanager - API v1 is only possible option after K8s 1.22
|
REMOVED option apiVersionOverrides.certmanager - API v1 is only possible option after K8s 1.22
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
|
@ -6,20 +6,6 @@ Return the target Kubernetes version
|
||||||
{{- default .Capabilities.KubeVersion.Version .Values.kubeVersionOverride }}
|
{{- default .Capabilities.KubeVersion.Version .Values.kubeVersionOverride }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
||||||
{{/*
|
|
||||||
Return the appropriate apiVersion for autoscaling
|
|
||||||
*/}}
|
|
||||||
{{- define "argo-cd.apiVersion.autoscaling" -}}
|
|
||||||
{{- if .Values.apiVersionOverrides.autoscaling -}}
|
|
||||||
{{- print .Values.apiVersionOverrides.autoscaling -}}
|
|
||||||
{{- else if semverCompare "<1.23-0" (include "argo-cd.kubeVersion" .) -}}
|
|
||||||
{{- print "autoscaling/v2beta1" -}}
|
|
||||||
{{- else -}}
|
|
||||||
{{- print "autoscaling/v2" -}}
|
|
||||||
{{- end -}}
|
|
||||||
{{- end -}}
|
|
||||||
|
|
||||||
|
|
||||||
{{/*
|
{{/*
|
||||||
Return the appropriate apiVersion for GKE resources
|
Return the appropriate apiVersion for GKE resources
|
||||||
*/}}
|
*/}}
|
||||||
|
|
|
@ -1,45 +1,37 @@
|
||||||
{{- if .Values.repoServer.autoscaling.enabled }}
|
{{- if .Values.repoServer.autoscaling.enabled }}
|
||||||
apiVersion: {{ include "argo-cd.apiVersion.autoscaling" . }}
|
apiVersion: autoscaling/v2
|
||||||
kind: HorizontalPodAutoscaler
|
kind: HorizontalPodAutoscaler
|
||||||
metadata:
|
metadata:
|
||||||
labels:
|
name: {{ include "argo-cd.repoServer.fullname" . }}
|
||||||
{{- include "argo-cd.labels" (dict "context" . "component" .Values.repoServer.name "name" (printf "%s-hpa" .Values.repoServer.name)) | nindent 4 }}
|
|
||||||
name: {{ template "argo-cd.repoServer.fullname" . }}-hpa
|
|
||||||
namespace: {{ .Release.Namespace | quote }}
|
namespace: {{ .Release.Namespace | quote }}
|
||||||
|
labels:
|
||||||
|
{{- include "argo-cd.labels" (dict "context" . "component" .Values.repoServer.name "name" .Values.repoServer.name) | nindent 4 }}
|
||||||
spec:
|
spec:
|
||||||
scaleTargetRef:
|
scaleTargetRef:
|
||||||
apiVersion: apps/v1
|
apiVersion: apps/v1
|
||||||
kind: Deployment
|
kind: Deployment
|
||||||
name: {{ template "argo-cd.repoServer.fullname" . }}
|
name: {{ include "argo-cd.repoServer.fullname" . }}
|
||||||
minReplicas: {{ .Values.repoServer.autoscaling.minReplicas }}
|
minReplicas: {{ .Values.repoServer.autoscaling.minReplicas }}
|
||||||
maxReplicas: {{ .Values.repoServer.autoscaling.maxReplicas }}
|
maxReplicas: {{ .Values.repoServer.autoscaling.maxReplicas }}
|
||||||
metrics:
|
metrics:
|
||||||
{{- if .Values.repoServer.autoscaling.metrics }}
|
{{- with .Values.repoServer.autoscaling.metrics }}
|
||||||
{{- toYaml .Values.repoServer.autoscaling.metrics | nindent 4 }}
|
{{- toYaml . | nindent 4 }}
|
||||||
{{- else }}
|
{{- else }}
|
||||||
{{- with .Values.repoServer.autoscaling.targetMemoryUtilizationPercentage }}
|
{{- with .Values.repoServer.autoscaling.targetMemoryUtilizationPercentage }}
|
||||||
- type: Resource
|
- type: Resource
|
||||||
resource:
|
resource:
|
||||||
name: memory
|
name: memory
|
||||||
{{- if eq (include "argo-cd.apiVersion.autoscaling" $) "autoscaling/v2beta1" }}
|
|
||||||
targetAverageUtilization: {{ . }}
|
|
||||||
{{- else }}
|
|
||||||
target:
|
target:
|
||||||
averageUtilization: {{ . }}
|
|
||||||
type: Utilization
|
type: Utilization
|
||||||
{{- end }}
|
averageUtilization: {{ . }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- with .Values.repoServer.autoscaling.targetCPUUtilizationPercentage }}
|
{{- with .Values.repoServer.autoscaling.targetCPUUtilizationPercentage }}
|
||||||
- type: Resource
|
- type: Resource
|
||||||
resource:
|
resource:
|
||||||
name: cpu
|
name: cpu
|
||||||
{{- if eq (include "argo-cd.apiVersion.autoscaling" $) "autoscaling/v2beta1" }}
|
|
||||||
targetAverageUtilization: {{ . }}
|
|
||||||
{{- else }}
|
|
||||||
target:
|
target:
|
||||||
averageUtilization: {{ . }}
|
|
||||||
type: Utilization
|
type: Utilization
|
||||||
{{- end }}
|
averageUtilization: {{ . }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- with .Values.repoServer.autoscaling.behavior }}
|
{{- with .Values.repoServer.autoscaling.behavior }}
|
||||||
|
|
|
@ -1,47 +1,39 @@
|
||||||
{{- if .Values.server.autoscaling.enabled }}
|
{{- if .Values.server.autoscaling.enabled }}
|
||||||
apiVersion: {{ include "argo-cd.apiVersion.autoscaling" . }}
|
apiVersion: autoscaling/v2
|
||||||
kind: HorizontalPodAutoscaler
|
kind: HorizontalPodAutoscaler
|
||||||
metadata:
|
metadata:
|
||||||
labels:
|
name: {{ include "argo-cd.server.fullname" . }}
|
||||||
{{- include "argo-cd.labels" (dict "context" . "component" .Values.server.name "name" (printf "%s-hpa" .Values.server.name)) | nindent 4 }}
|
|
||||||
name: {{ template "argo-cd.server.fullname" . }}-hpa
|
|
||||||
namespace: {{ .Release.Namespace | quote }}
|
namespace: {{ .Release.Namespace | quote }}
|
||||||
|
labels:
|
||||||
|
{{- include "argo-cd.labels" (dict "context" . "component" .Values.server.name "name" .Values.server.name) | nindent 4 }}
|
||||||
spec:
|
spec:
|
||||||
scaleTargetRef:
|
scaleTargetRef:
|
||||||
apiVersion: apps/v1
|
apiVersion: apps/v1
|
||||||
kind: Deployment
|
kind: Deployment
|
||||||
name: {{ template "argo-cd.server.fullname" . }}
|
name: {{ include "argo-cd.server.fullname" . }}
|
||||||
minReplicas: {{ .Values.server.autoscaling.minReplicas }}
|
minReplicas: {{ .Values.server.autoscaling.minReplicas }}
|
||||||
maxReplicas: {{ .Values.server.autoscaling.maxReplicas }}
|
maxReplicas: {{ .Values.server.autoscaling.maxReplicas }}
|
||||||
metrics:
|
metrics:
|
||||||
{{- if .Values.server.autoscaling.metrics }}
|
{{- with .Values.server.autoscaling.metrics }}
|
||||||
{{ toYaml .Values.server.autoscaling.metrics | nindent 4 }}
|
{{- toYaml . | nindent 4 }}
|
||||||
{{- else }}
|
{{- else }}
|
||||||
{{- with .Values.server.autoscaling.targetMemoryUtilizationPercentage }}
|
{{- with .Values.server.autoscaling.targetMemoryUtilizationPercentage }}
|
||||||
- type: Resource
|
- type: Resource
|
||||||
resource:
|
resource:
|
||||||
name: memory
|
name: memory
|
||||||
{{- if eq (include "argo-cd.apiVersion.autoscaling" $) "autoscaling/v2beta1" }}
|
|
||||||
targetAverageUtilization: {{ . }}
|
|
||||||
{{- else }}
|
|
||||||
target:
|
target:
|
||||||
averageUtilization: {{ . }}
|
|
||||||
type: Utilization
|
type: Utilization
|
||||||
{{- end }}
|
averageUtilization: {{ . }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- with .Values.server.autoscaling.targetCPUUtilizationPercentage }}
|
{{- with .Values.server.autoscaling.targetCPUUtilizationPercentage }}
|
||||||
- type: Resource
|
- type: Resource
|
||||||
resource:
|
resource:
|
||||||
name: cpu
|
name: cpu
|
||||||
{{- if eq (include "argo-cd.apiVersion.autoscaling" $) "autoscaling/v2beta1" }}
|
|
||||||
targetAverageUtilization: {{ . }}
|
|
||||||
{{- else }}
|
|
||||||
target:
|
target:
|
||||||
averageUtilization: {{ . }}
|
|
||||||
type: Utilization
|
type: Utilization
|
||||||
|
averageUtilization: {{ . }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
{{- end}}
|
|
||||||
{{- with .Values.server.autoscaling.behavior }}
|
{{- with .Values.server.autoscaling.behavior }}
|
||||||
behavior:
|
behavior:
|
||||||
{{- toYaml . | nindent 4 }}
|
{{- toYaml . | nindent 4 }}
|
||||||
|
|
|
@ -14,8 +14,6 @@ kubeVersionOverride: ""
|
||||||
apiVersionOverrides:
|
apiVersionOverrides:
|
||||||
# -- String to override apiVersion of GKE resources rendered by this helm chart
|
# -- String to override apiVersion of GKE resources rendered by this helm chart
|
||||||
cloudgoogle: "" # cloud.google.com/v1
|
cloudgoogle: "" # cloud.google.com/v1
|
||||||
# -- String to override apiVersion of autoscaling rendered by this helm chart
|
|
||||||
autoscaling: "" # autoscaling/v2
|
|
||||||
|
|
||||||
# -- Create aggregated roles that extend existing cluster roles to interact with argo-cd resources
|
# -- Create aggregated roles that extend existing cluster roles to interact with argo-cd resources
|
||||||
## Ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/#aggregated-clusterroles
|
## Ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/#aggregated-clusterroles
|
||||||
|
@ -1460,7 +1458,6 @@ server:
|
||||||
# -- Average memory utilization percentage for the Argo CD server [HPA]
|
# -- Average memory utilization percentage for the Argo CD server [HPA]
|
||||||
targetMemoryUtilizationPercentage: 50
|
targetMemoryUtilizationPercentage: 50
|
||||||
# -- Configures the scaling behavior of the target in both Up and Down directions.
|
# -- Configures the scaling behavior of the target in both Up and Down directions.
|
||||||
# This is only available on HPA apiVersion `autoscaling/v2beta2` and newer
|
|
||||||
behavior: {}
|
behavior: {}
|
||||||
# scaleDown:
|
# scaleDown:
|
||||||
# stabilizationWindowSeconds: 300
|
# stabilizationWindowSeconds: 300
|
||||||
|
@ -2030,7 +2027,6 @@ repoServer:
|
||||||
# -- Average memory utilization percentage for the repo server [HPA]
|
# -- Average memory utilization percentage for the repo server [HPA]
|
||||||
targetMemoryUtilizationPercentage: 50
|
targetMemoryUtilizationPercentage: 50
|
||||||
# -- Configures the scaling behavior of the target in both Up and Down directions.
|
# -- Configures the scaling behavior of the target in both Up and Down directions.
|
||||||
# This is only available on HPA apiVersion `autoscaling/v2beta2` and newer
|
|
||||||
behavior: {}
|
behavior: {}
|
||||||
# scaleDown:
|
# scaleDown:
|
||||||
# stabilizationWindowSeconds: 300
|
# stabilizationWindowSeconds: 300
|
||||||
|
|
Loading…
Reference in a new issue