Skip to content

Kubernetes Dashboard Metrics scraper

The Kubernetes Dashboard Metrics scraper is a component of the Kubernetes Dashboard responsible for retrieving and processing cluster metrics^[400-devops__06-Kubernetes__devops-helm__terraform-helm__helm__README.md]. When deployed via the official Helm chart, it appears as a containerized sidecar or companion service, typically distinct from the main dashboard pod^[400-devops__06-Kubernetes__devops-helm__terraform-helm__helm__README.md].

Configuration

The deployment of the Metrics scraper can be toggled using the metricsScraper.enabled parameter^[400-devops__06-Kubernetes__devops-helm__terraform-helm__helm__README.md]. By default, this parameter is set to false, meaning the scraper must be explicitly enabled during installation or upgrade^[400-devops__06-Kubernetes__devops-helm__terraform-helm__helm__README.md].

If enabled, the component uses a container image from the kubernetesui/metrics-scraper repository^[400-devops__06-Kubernetes__devops-helm__terraform-helm__helm__README.md].

Container Settings

The Helm chart provides specific configuration options for the scraper's container runtime and security context:

  • Image Tag: The default tag for the scraper image is v1.0.4^[400-devops__06-Kubernetes__devops-helm__terraform-helm__helm__README.md].
  • Security Context: The chart defaults to a strict security posture for the scraper container, including allowPrivilegeEscalation: false, a readOnlyRootFilesystem, and running as a specific user/group (UID 1001, GID 2001)^[400-devops__06-Kubernetes__devops-helm__terraform-helm__helm__README.md].

Permissions

To facilitate the collection of Metrics, the chart can automatically create the necessary [[RBAC]] resources. If rbac.create is true, the rbac.clusterRoleMetrics parameter allows for the creation of an additional ClusterRole and RoleBinding specifically designed to grant access to these metrics^[400-devops__06-Kubernetes__devops-helm__terraform-helm__helm__README.md].

Sources

^[400-devops__06-Kubernetes__devops-helm__terraform-helm__helm__README.md]