diff --git a/stable/aws-cloudwatch-metrics/Chart.yaml b/stable/aws-cloudwatch-metrics/Chart.yaml index d6ac4d066..6912b7cde 100644 --- a/stable/aws-cloudwatch-metrics/Chart.yaml +++ b/stable/aws-cloudwatch-metrics/Chart.yaml @@ -1,7 +1,7 @@ apiVersion: v1 name: aws-cloudwatch-metrics description: A Helm chart to deploy aws-cloudwatch-metrics project -version: 0.0.11 +version: 0.0.12 appVersion: "1.300032.2b361" home: https://github.com/aws/eks-charts icon: https://raw.githubusercontent.com/aws/eks-charts/master/docs/logo/aws.png diff --git a/stable/aws-cloudwatch-metrics/README.md b/stable/aws-cloudwatch-metrics/README.md index ff0ea14b3..552a4b49e 100755 --- a/stable/aws-cloudwatch-metrics/README.md +++ b/stable/aws-cloudwatch-metrics/README.md @@ -27,6 +27,7 @@ helm upgrade --install aws-cloudwatch-metrics \ | `image.pullPolicy` | Pull policy for the image | `IfNotPresent` | ✔ | `clusterName` | Name of your cluster | `cluster_name` | ✔ | `enhancedContainerInsights` | EKS cluster with enhanced monitoring | `true` | +| `metricsCollectionInterval` | agent collection interval | `60` | `serviceAccount.create` | Whether a new service account should be created | `true` | | `serviceAccount.name` | Service account to be used | | | `hostNetwork` | Allow to use the network namespace and network resources of the node | `false` | diff --git a/stable/aws-cloudwatch-metrics/templates/configmap.yaml b/stable/aws-cloudwatch-metrics/templates/configmap.yaml index 8710c8d86..fb6dc78fb 100755 --- a/stable/aws-cloudwatch-metrics/templates/configmap.yaml +++ b/stable/aws-cloudwatch-metrics/templates/configmap.yaml @@ -6,13 +6,17 @@ metadata: {{- include "aws-cloudwatch-metrics.labels" . | nindent 4 }} data: cwagentconfig.json: | + {{- $metricsCollectionInterval := .Values.metricsCollectionInterval | default 60 | int }} + {{- if lt $metricsCollectionInterval 15 }} + {{- fail "metricsCollectionInterval allows you to specify how often the agent collects metrics. The default is 60 seconds. The default cadvisor collection interval in kubelet is 15 seconds, so don't set this value to less than 15 seconds." }} + {{- end }} { "logs": { "metrics_collected": { "kubernetes": { "cluster_name": "{{ .Values.clusterName }}", "enhanced_container_insights": {{ .Values.enhancedContainerInsights.enabled }}, - "metrics_collection_interval": 60 + "metrics_collection_interval": {{ $metricsCollectionInterval }} } }, "force_flush_interval": 5 diff --git a/stable/aws-cloudwatch-metrics/values.yaml b/stable/aws-cloudwatch-metrics/values.yaml index 0967bb132..575c787c9 100644 --- a/stable/aws-cloudwatch-metrics/values.yaml +++ b/stable/aws-cloudwatch-metrics/values.yaml @@ -4,6 +4,7 @@ image: pullPolicy: IfNotPresent clusterName: cluster_name +metricsCollectionInterval: 60 enhancedContainerInsights: enabled: true