From 8ccb2378cc97f2bf5145dc5cb3c7ce25123bc860 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?M=C3=A5rten=20Svantesson?= Date: Mon, 2 Sep 2024 12:58:10 +0200 Subject: [PATCH] feat: add maintained cluster autoscaler helm chart --- .../autoscaler/cluster-autoscaler/defaults.yaml | 3 +++ .../cluster-autoscaler/values.yaml.gotmpl | 15 +++++++++++++++ charts/repositories.yml | 5 ++++- 3 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 charts/autoscaler/cluster-autoscaler/defaults.yaml create mode 100644 charts/autoscaler/cluster-autoscaler/values.yaml.gotmpl diff --git a/charts/autoscaler/cluster-autoscaler/defaults.yaml b/charts/autoscaler/cluster-autoscaler/defaults.yaml new file mode 100644 index 000000000..d4fe97e05 --- /dev/null +++ b/charts/autoscaler/cluster-autoscaler/defaults.yaml @@ -0,0 +1,3 @@ +gitUrl: https://github.com/kubernetes/autoscaler/tree/master/charts/cluster-autoscaler +namespace: kube-system +version: 9.37.0 diff --git a/charts/autoscaler/cluster-autoscaler/values.yaml.gotmpl b/charts/autoscaler/cluster-autoscaler/values.yaml.gotmpl new file mode 100644 index 000000000..7182baeb4 --- /dev/null +++ b/charts/autoscaler/cluster-autoscaler/values.yaml.gotmpl @@ -0,0 +1,15 @@ +{{- if eq .Values.jxRequirements.cluster.provider "eks" }} +autoDiscovery: + enabled: true + clusterName: {{ .Values.jxRequirements.cluster.clusterName }} +awsRegion: {{ .Values.jxRequirements.cluster.region }} +{{- end }} + +rbac: + create: true +{{- if and (hasKey .Values.jxRequirements.cluster "project") (hasKey .Values.jxRequirements.cluster "clusterName") (eq .Values.jxRequirements.cluster.provider "eks") }} + serviceAccount: + name: cluster-autoscaler + annotations: + eks.amazonaws.com/role-arn: arn:aws:iam::{{ .Values.jxRequirements.cluster.project }}:role/{{ .Values.jxRequirements.cluster.clusterName }}-cluster-autoscaler-cluster-autoscaler +{{- end }} diff --git a/charts/repositories.yml b/charts/repositories.yml index b0b55cd9d..ce2aba379 100644 --- a/charts/repositories.yml +++ b/charts/repositories.yml @@ -49,4 +49,7 @@ repositories: - https://argoproj.github.io/argo-helm - prefix: wave-k8s urls: - - https://wave-k8s.github.io/wave/ \ No newline at end of file + - https://wave-k8s.github.io/wave/ +- prefix: autoscaler + urls: + - https://kubernetes.github.io/autoscaler