KubMonitor provides a real-time, high-fidelity dashboard for your Kubernetes clusters directly in your terminal. Inspired by tools like nvitop and btop, it combines cluster quotas with local machine metrics in a slick, responsive TUI (Terminal User Interface).
- 📊 Real-time Dashboard: Live updates of CPU, Memory, and GPU usage.
- ☸️ Namespace Scoped: Monitor specific Kubernetes namespaces with ease.
- 💻 Hybrid Metrics: View both K8s Cluster Quotas and Local Machine stats side-by-side.
- ⚡ Reactive TUI: Built with
Refreshedlayouts using Rich. - 🖥️ Cross-Platform: Works seamlessly on Linux, macOS, and Windows.
Install via pip:
pip install kubmonitor-cliOr install from source:
git clone https://github.com/vios-s/kubmonitor-cli.git
cd kubmonitor-cli
pip install .View all available options and usage information:
kubmonitor --help
# or
kubmonitor -hCheck the version:
kubmonitor --version
# or
kubmonitor -VSimply run the command followed by the target namespace:
kubmonitor <namespace>Example:
kubmonitor eidf098nsIf no namespace is specified, it defaults to default:
kubmonitorFor testing or debugging purposes without requiring access to a Kubernetes cluster, you can use the --mock flag to run KubMonitor with simulated data:
kubmonitor --mockNote: When using --mock, you cannot specify a namespace. Mock mode uses generated test data and doesn't connect to a real cluster.
This will generate realistic mock data including:
- Simulated resource quotas (CPU, Memory, GPU)
- Mock Kubernetes jobs with various states (running, completed, failed)
- Mock pods with realistic resource usage patterns
- Generated timestamps and durations
| Key | Description |
|---|---|
↑ / ↓ |
Navigate up and down |
q |
Quit the application |
Ctrl+C |
Force Exit |
- Rich: For beautiful terminal formatting and layout.
- Psutil: For retrieving local system metrics.
- Kubectl: Under the hood, it uses your local
kubectlconfiguration to fetch cluster data.
This project is licensed under the MIT License - see the LICENSE file for details.
