From 6533792044c917cc92e11db1bd4f715ee8b720b5 Mon Sep 17 00:00:00 2001 From: Bianca Burtoiu Date: Fri, 23 Aug 2024 16:01:26 +0200 Subject: [PATCH] Set up InstanceAllowLists ConfigMap --- ...commendations-allowlists-config-map-template.yaml | 12 ++++++++++++ cost-analyzer/values.yaml | 4 ++++ 2 files changed, 16 insertions(+) create mode 100644 cost-analyzer/templates/savings-recommendations-allowlists-config-map-template.yaml diff --git a/cost-analyzer/templates/savings-recommendations-allowlists-config-map-template.yaml b/cost-analyzer/templates/savings-recommendations-allowlists-config-map-template.yaml new file mode 100644 index 000000000..ebd49b62a --- /dev/null +++ b/cost-analyzer/templates/savings-recommendations-allowlists-config-map-template.yaml @@ -0,0 +1,12 @@ +{{- if .Values.kubecostProductConfigs }} +{{- if .Values.kubecostProductConfigs.savingsRecommendationsAllowLists }} +apiVersion: v1 +kind: ConfigMap +metadata: + name: "savings-recommendations-instance-allow-lists" + namespace: {{ .Release.Namespace }} + labels: {{ include "cost-analyzer.commonLabels" . | nindent 4 }} +data: + allow-lists.json: '{{ toJson .Values.kubecostProductConfigs.savingsRecommendationsAllowLists }}' +{{- end -}} +{{- end -}} \ No newline at end of file diff --git a/cost-analyzer/values.yaml b/cost-analyzer/values.yaml index 7afaa5991..0a375bc34 100644 --- a/cost-analyzer/values.yaml +++ b/cost-analyzer/values.yaml @@ -3447,6 +3447,10 @@ costEventsAudit: # hideCloudIntegrationsUI: false # hideBellIcon: false # hideTeams: false +# savingsRecommendationsAllowLists: # Define select list of instance types to be evaluated in computing Savings Recommendations +# AWS: [] +# GCP: [] +# Azure: [] ## Specify an existing Kubernetes Secret holding the cloud integration information. This Secret must contain ## a key with name `cloud-integration.json` and the contents must be in a specific format. It is expected