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

Add vpa crs for keda-operator and metrics-server #562

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
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
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ $ helm repo add kedacore https://kedacore.github.io/charts
$ helm search repo kedacore
NAME CHART VERSION APP VERSION DESCRIPTION
kedacore/external-scaler-azure-cosmos-db 0.1.0 0.1.0 Event-based autoscaler for Azure Cosmos DB chan...
kedacore/keda 2.12.0 2.12.0 Event-based autoscaler for workloads on Kubernetes
kedacore/keda 2.13.0 2.12.0 Event-based autoscaler for workloads on Kubernetes
QuantumEnigmaa marked this conversation as resolved.
Show resolved Hide resolved
kedacore/keda-add-ons-http 0.6.0 0.6.0 Event-based autoscaler for HTTP workloads on Ku...
QuantumEnigmaa marked this conversation as resolved.
Show resolved Hide resolved
```

Expand Down
Binary file modified docs/external-scaler-azure-cosmos-db-0.1.0.tgz
Binary file not shown.
166 changes: 95 additions & 71 deletions docs/index.yaml

Large diffs are not rendered by default.

Binary file added docs/keda-2.13.0.tgz
Binary file not shown.
Binary file modified docs/keda-add-ons-http-0.6.0.tgz
Binary file not shown.
2 changes: 1 addition & 1 deletion keda/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ kubeVersion: ">=v1.23.0-0"

# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
version: 2.12.0
QuantumEnigmaa marked this conversation as resolved.
Show resolved Hide resolved
version: 2.13.0

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application.
Expand Down
10 changes: 10 additions & 0 deletions keda/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,11 @@ their default values.
| `securityContext.operator` | object | [See below](#KEDA-is-secure-by-default) | [Security context] of the operator container |
| `topologySpreadConstraints.operator` | list | `[]` | [Pod Topology Constraints] of KEDA operator pod |
| `upgradeStrategy.operator` | object | `{}` | Capability to configure [Deployment upgrade strategy] for operator |
| `verticalPodAutoscaler.keda.cpu.maxAllowed` | int | `2` | |
zroubalik marked this conversation as resolved.
Show resolved Hide resolved
| `verticalPodAutoscaler.keda.cpu.minAllowed` | string | `"20m"` | |
| `verticalPodAutoscaler.keda.enabled` | bool | `true` | Enables the creation of a vpa for the keda-operator |
| `verticalPodAutoscaler.keda.memory.maxAllowed` | string | `"2Gi"` | |
| `verticalPodAutoscaler.keda.memory.minAllowed` | string | `"200Mi"` | |
| `volumes.keda.extraVolumeMounts` | list | `[]` | Extra volume mounts for KEDA deployment |
| `volumes.keda.extraVolumes` | list | `[]` | Extra volumes for KEDA deployment |

Expand Down Expand Up @@ -162,6 +167,11 @@ their default values.
| `service.type` | string | `"ClusterIP"` | KEDA Metric Server service type |
| `topologySpreadConstraints.metricsServer` | list | `[]` | [Pod Topology Constraints] of KEDA metrics apiserver pod |
| `upgradeStrategy.metricsApiServer` | object | `{}` | Capability to configure [Deployment upgrade strategy] for Metrics Api Server |
| `verticalPodAutoscaler.metricsApiServer.cpu.maxAllowed` | int | `2` | |
| `verticalPodAutoscaler.metricsApiServer.cpu.minAllowed` | string | `"20m"` | |
| `verticalPodAutoscaler.metricsApiServer.enabled` | bool | `true` | Enables the creation of a vpa for the keda-operator-metrics-apiserver |
| `verticalPodAutoscaler.metricsApiServer.memory.maxAllowed` | string | `"2Gi"` | |
| `verticalPodAutoscaler.metricsApiServer.memory.minAllowed` | string | `"200Mi"` | |
| `volumes.metricsApiServer.extraVolumeMounts` | list | `[]` | Extra volume mounts for metric server deployment |
| `volumes.metricsApiServer.extraVolumes` | list | `[]` | Extra volumes for metric server deployment |

Expand Down
2 changes: 1 addition & 1 deletion keda/templates/NOTES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ WARNING - prometheus.webhooks.serviceMonitor.relabellings is deprecated, please

{{- if lt .Capabilities.KubeVersion.Minor "26" }}
-------------------------------------------------------------------------------------
WARNING - Running on unsupported Kubernetes version "1.{{.Capabilities.KubeVersion.Minor}}". KEDA 2.12 is supported and tested on Kubernetes "1.26" or higher. See https://keda.sh/docs/2.12/operate/cluster/ for details.
WARNING - Running on unsupported Kubernetes version "1.{{.Capabilities.KubeVersion.Minor}}". KEDA 2.13 is supported and tested on Kubernetes "1.26" or higher. See https://keda.sh/docs/2.13/operate/cluster/ for details.
-------------------------------------------------------------------------------------
{{- end }}

Expand Down
30 changes: 30 additions & 0 deletions keda/templates/manager/verticalpodautoscaler.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{{- if .Values.verticalPodAutoscaler.keda.enabled }}
apiVersion: autoscaling.k8s.io/v1
kind: VerticalPodAutoscaler
metadata:
name: {{ .Values.operator.name }}-vpa
namespace: {{ .Release.Namespace }}
annotations:
{{- toYaml .Values.additionalAnnotations | nindent 4 }}
labels:
{{- include "keda.labels" . | indent 4 }}
spec:
targetRef:
apiVersion: "apps/v1"
kind: Deployment
name: {{ .Values.operator.name }}
resourcePolicy:
containerPolicies:
- containerName: '*'
controlledResources:
- cpu
- memory
maxAllowed:
cpu: {{ .Values.verticalPodAutoscaler.keda.cpu.maxAllowed }}
memory: {{ .Values.verticalPodAutoscaler.keda.memory.maxAllowed }}
minAllowed:
cpu: {{ .Values.verticalPodAutoscaler.keda.cpu.minAllowed }}
memory: {{ .Values.verticalPodAutoscaler.keda.memory.minAllowed }}
updatePolicy:
updateMode: "Auto"
{{- end }}
30 changes: 30 additions & 0 deletions keda/templates/metrics-server/verticalpodautoscaler.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{{- if .Values.verticalPodAutoscaler.metricsApiServer.enabled }}
apiVersion: autoscaling.k8s.io/v1
kind: VerticalPodAutoscaler
metadata:
name: {{ .Values.operator.name }}-metrics-apiserver-vpa
namespace: {{ .Release.Namespace }}
annotations:
{{- toYaml .Values.additionalAnnotations | nindent 4 }}
labels:
{{- include "keda.labels" . | indent 4 }}
spec:
targetRef:
apiVersion: "apps/v1"
kind: Deployment
name: {{ .Values.operator.name }}-metrics-apiserver
resourcePolicy:
containerPolicies:
- containerName: '*'
controlledResources:
- cpu
- memory
maxAllowed:
cpu: {{ .Values.verticalPodAutoscaler.metricsApiServer.cpu.maxAllowed }}
memory: {{ .Values.verticalPodAutoscaler.metricsApiServer.memory.maxAllowed }}
minAllowed:
cpu: {{ .Values.verticalPodAutoscaler.metricsApiServer.cpu.minAllowed }}
memory: {{ .Values.verticalPodAutoscaler.metricsApiServer.memory.minAllowed }}
updatePolicy:
updateMode: "Auto"
{{- end }}
20 changes: 20 additions & 0 deletions keda/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,26 @@ image:
# -- Kubernetes cluster domain
clusterDomain: cluster.local

verticalPodAutoscaler:
zroubalik marked this conversation as resolved.
Show resolved Hide resolved
keda:
# -- Enables the creation of a vpa for the keda-operator
enabled: true
QuantumEnigmaa marked this conversation as resolved.
Show resolved Hide resolved
cpu:
minAllowed: 20m
maxAllowed: 2
memory:
minAllowed: 200Mi
maxAllowed: 2Gi
metricsApiServer:
# -- Enables the creation of a vpa for the keda-operator-metrics-apiserver
enabled: true
cpu:
minAllowed: 20m
maxAllowed: 2
memory:
minAllowed: 200Mi
maxAllowed: 2Gi

crds:
# -- Defines whether the KEDA CRDs have to be installed or not.
install: true
Expand Down
Loading