Connecting a Kubernetes cluster
Deploy the DigiUsher Kubernetes agent with Helm and connect cluster metrics to DigiUsher.
Overview
DigiUsher connects to Kubernetes through the digiusher-k8s-agent Helm chart. The agent runs inside your cluster, collects Kubernetes metadata and usage metrics, and pushes the data to DigiUsher with a token generated when you create the Kubernetes data source.
The chart installs these components:
| Component | Purpose |
|---|---|
digiusher-k8s-api | Internal API service that receives remote-write metrics from the collector |
digiusher-k8s-uploader | Uploads buffered metrics to DigiUsher |
digiusher-k8s-redis | Buffers metrics before upload |
| Grafana Alloy | Scrapes Kubernetes and kubelet metrics |
| kube-state-metrics | Exposes Kubernetes object metadata used by DigiUsher |
Prerequisites
| Requirement | Details |
|---|---|
| Helm | Helm must be installed locally. See the Helm documentation if you need to install it. |
| Kubernetes access | Use a kubeconfig context with permission to create namespaces, workloads, services, service accounts, config maps, secrets, and persistent volume claims. |
| DigiUsher access | You need permission to create a Kubernetes data source in DigiUsher. |
| Outbound access | The agent uploader must be able to reach https://app.digiusher.com/api/v3. |
| Storage | The default Redis deployment creates a 4Gi persistent volume claim. |
Keep the default namespace
Install the chart in the digiusher-k8s namespace unless DigiUsher support
instructs you to customize the chart. The default collector configuration
references services in this namespace.
Connect the Data Source
Create the Kubernetes Data Source
- Open DigiUsher App.
- Go to Connectors which is grouped under System.
- Click Add Source.
- Select Kubernetes and click continue.
- Enter a Display Name for the cluster.
- Continue to the confirmation step and click Save Data Source.
DigiUsher generates an API token when the Kubernetes data source is created. Copy the token when it is shown in the UI.
This token is shown again
The Kubernetes API token is always shown in the connectors page.
Add the DigiUsher Helm Repository
helm repo add digiusher https://digiusher.github.io/helm-charts
helm repo updateYou can confirm the chart is available with:
helm search repo digiusherInstall the Kubernetes Agent
Replace <insert_api_token> with the token shown by DigiUsher when you created the Kubernetes data source.
helm install digiusher-k8s-agent digiusher/digiusher-k8s-agent \
--set uploader.env.digiusher_k8s_api_token=<insert_api_token> \
--namespace digiusher-k8s \
--create-namespaceThe token is stored in a Kubernetes secret named digiusher-k8s-api-token with the key K8S_API_TOKEN.
Verify the Installation
Check the Helm release:
helm status digiusher-k8s-agent --namespace digiusher-k8sCheck that the DigiUsher workloads are running:
kubectl get pods --namespace digiusher-k8sCheck the services created by the chart:
kubectl get services --namespace digiusher-k8sAfter the agent starts successfully, Kubernetes data will appear in DigiUsher after the first successful upload and processing cycle.
Configuration Reference
The default install command is recommended for most clusters. The chart exposes additional values for advanced environments.
| Helm value | Default | Description |
|---|---|---|
uploader.env.digiusher_k8s_api_token | <replace_me> | Token generated by DigiUsher for the Kubernetes data source. Required. |
uploader.env.digiusher_k8s_api_url | https://app.digiusher.com/api/v3 | DigiUsher API endpoint used by the uploader. |
api.service.type | ClusterIP | Internal service type for digiusher-k8s-api. |
api.service.port | 8111 | Internal API service port used by the collector remote-write pipeline. |
redis.enabled | true | Deploys Redis as the local metrics buffer. |
redis.pvc.size | 4Gi | Persistent volume claim size for Redis. |
serviceAccount.name | digiusher-k8s-agent-sa | Service account used by the agent components. |
global.environment.shared.redis_max_buffer_size_sec | 86400 | Maximum Redis buffer window in seconds. |
global.environment.shared.grace_period_seconds | 120 | Grace period before buffered data is processed. |
Advanced configuration
If you need to change namespaces, image settings, node selectors, tolerations,
affinity, resource limits, or Redis settings, create a values file and pass it
with helm install -f values.yaml. Keep the required token value set through
a secret management process appropriate for your environment.
Collected Metrics
The default chart configuration collects Kubernetes metadata and resource usage required for DigiUsher Kubernetes cost allocation and rightsizing. The collection pipeline includes kube-state-metrics, cAdvisor metrics, and kubelet volume statistics.
| Source | Examples of collected data |
|---|---|
| kube-state-metrics | Namespaces, nodes, pods, deployments, daemonsets, replica sets, services, jobs, persistent volumes, persistent volume claims, storage classes, resource quotas |
| cAdvisor | Container CPU usage, memory usage, network receive bytes, network transmit bytes |
| kubelet | Persistent volume used bytes, capacity bytes, and available bytes |
Upgrade the Agent
Refresh the Helm repository and upgrade the release:
helm repo update
helm upgrade digiusher-k8s-agent digiusher/digiusher-k8s-agent \
--set uploader.env.digiusher_k8s_api_token=<insert_api_token> \
--namespace digiusher-k8sIf you installed the chart with a custom values file, include the same file during upgrade:
helm upgrade digiusher-k8s-agent digiusher/digiusher-k8s-agent \
-f values.yaml \
--namespace digiusher-k8sUninstall the Agent
To remove the DigiUsher Kubernetes agent from the cluster:
helm uninstall digiusher-k8s-agent --namespace digiusher-k8sIf you no longer need the namespace and any remaining resources in it, remove the namespace separately:
kubectl delete namespace digiusher-k8sDeleting the namespace removes all resources inside it
Only delete the digiusher-k8s namespace if it is dedicated to the DigiUsher
agent.
Troubleshooting
| Issue | What to Check |
|---|---|
| Helm cannot find the chart | Run helm repo add digiusher https://digiusher.github.io/helm-charts and helm repo update, then retry helm search repo digiusher. |
| Pods are not starting | Run kubectl describe pod <pod-name> --namespace digiusher-k8s and check image pull, scheduling, persistent volume, and resource errors. |
| Token secret is missing | Confirm the install command included --set uploader.env.digiusher_k8s_api_token=<insert_api_token>. |
| Uploader cannot send data | Confirm cluster egress allows https://app.digiusher.com/api/v3. |
| No Kubernetes data appears in DigiUsher | Confirm all pods in digiusher-k8s are running, then wait for the first upload and processing cycle to complete. |
Please contact the DigiUsher Support Team at support@digiusher.com if you have any questions or face any issues.
DigiUsher Documentation