Skip to content

Commit

Permalink
Merge pull request #3673 from kubecost/federated-helm-checks
Browse files Browse the repository at this point in the history
add warning for federated storage
  • Loading branch information
jessegoodier authored Sep 16, 2024
2 parents e65993f + 9f79496 commit 2ff8470
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions cost-analyzer/templates/NOTES.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,4 @@ Please allow 25 minutes for Kubecost to gather metrics. A progress indicator wil
Having installation issues? View our Troubleshooting Guide at http://docs.kubecost.com/troubleshoot-install

{{- include "kubecostV2-3-notices" . -}}
{{- include "federatedStorageCheck" . -}}
8 changes: 8 additions & 0 deletions cost-analyzer/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,14 @@ Kubecost 2.0 preconditions
{{- end }}
{{- end -}}

{{- define "federatedStorageCheck" -}}
{{- if or (.Values.federatedETL).federatedStore (.Values.kubecostModel).federatedStorageConfig }}
{{- if and (not (eq (include "aggregator.deployMethod" .) "statefulset")) (not (.Values.federatedETL).agentOnly) }}
{{- printf "\n\n***Configuration issue detected:***\nWhen a federated store is provided, Kubecost should either be running as agentOnly or as a statefulset.\n.Values.federatedETL.agentOnly=true\nOr\n.Values.kubecostAggregator.deployMethod=statefulset\n***" }}
{{- end }}
{{- end }}
{{- end }}

{{- define "cloudIntegrationFromProductConfigs" }}
{
{{- if ((.Values.kubecostProductConfigs).athenaBucketName) }}
Expand Down

0 comments on commit 2ff8470

Please sign in to comment.