Sign inSign up

eramax/cluster-dashboard

By eramax

•Updated 4 months ago

Cluster Dashboard

Image
0

170

eramax/cluster-dashboard repository overview

⁠K3s Cluster Dashboard

Lightweight real-time K3s cluster monitoring dashboard — runs as a single container with zero dependencies.

⁠Quick Start

docker run -d \
  --name cluster-dashboard \
  -p 8080:80 \
  eramax/cluster-dashboard:latest

Open http://localhost:8080⁠

⁠Run in Kubernetes

apiVersion: apps/v1
kind: Deployment
metadata:
  name: cluster-dashboard
spec:
  replicas: 1
  selector:
    matchLabels:
      app: cluster-dashboard
  template:
    metadata:
      labels:
        app: cluster-dashboard
    spec:
      serviceAccountName: dashboard-sa
      containers:
      - name: dashboard
        image: eramax/cluster-dashboard:latest
        ports:
        - containerPort: 80
        env:
        - name: POD_NAME
          valueFrom:
            fieldRef:
              fieldPath: metadata.name
        - name: POD_IP
          valueFrom:
            fieldRef:
              fieldPath: status.podIP
        - name: NODE_NAME
          valueFrom:
            fieldRef:
              fieldPath: spec.nodeName
        - name: NODE_IP
          valueFrom:
            fieldRef:
              fieldPath: status.hostIP
        - name: NAMESPACE
          valueFrom:
            fieldRef:
              fieldPath: metadata.namespace

You'll need a ClusterRole + binding to read nodes, pods, services, ingresses, and deployments.

⁠Environment Variables

VariableDescription
POD_NAMEPod name (for display)
POD_IPPod IP (for display)
NODE_NAMENode name — enables node/cluster API queries
NODE_IPNode IP (for display)
NAMESPACENamespace (for display)
KUBERNETES_SERVICE_HOSTK8s API host (auto-detected in-cluster)
KUBERNETES_SERVICE_PORTK8s API port (auto-detected in-cluster)

⁠Endpoints

RouteDescription
/Dashboard UI
/jsonFull system snapshot as JSON
/history6-minute metrics history as JSON
/podsLive pod list
/servicesLive services
/ingressesLive ingresses
/healthzHealth check

⁠What's Monitored

  • CPU usage (per-core, load average, iowait)
  • Memory / Swap usage
  • Disk usage + IOPS + throughput
  • Network throughput per interface
  • TCP connections
  • Process counts (running/blocked)
  • CPU temperatures
  • Kubernetes node info + cluster state
  • Pods, Services, Ingresses (live view)

⁠Notes

  • Runs on port 80 inside the container
  • Metrics are collected from /proc and /sys — Linux only
  • Kubernetes API access uses the in-cluster service account token
  • Chart.js is loaded from CDN — internet access required for graphs

Tag summary

Content type

Image

Digest

sha256:3ac572b56…

Size

17 MB

Last updated

4 months ago

docker pull eramax/cluster-dashboard