KGV
is Kubernetes Global View or an acronym for GVK. It's a Terminal UI for observing and manipulating Kubernetes
resources.
- rhai-based data extraction for table views. Write a small script to extract the data for each column for a given GVK. Data extraction is parallel.
- Rhai module support. Use imports and reuse the code.
- Detail view templates are defined as Handlebars HTML templates, rendered against the resource context, and then converted to ASCII using cursive-markup.
- Live reloading support for the rhai engine and templates.
- Live updates for the detail, YAML, and list views.
- Collecting initial GVK resource names is cached. Startup on overprovisioned or overloaded k8s installations is faster.
- Multiple window support. Open multiple windows (logs, list views, list details views, or just details views) and switch between them. Switching is instant.
- Custom user dirs support. Specify your modules and templates dirs with CMD arguments.
- Rhai debugs are transferred to the main debug window
- Handlebars template includes and inheritance support
- YAML partial code extractors for Handlebars (use
to_yaml
helper)
~
: Show Debug ConsoleEsc
: Close the current windowCtrl+s
: executekubectl exec -it
Alt+=
: Show windows viewCtrl+p
: Dump rhai object to tempF5
: Refresh the view (clears deleted items)Ctrl+y
: Show Resource YAML viewCtrl+/
: Show a list of registered GVKsCtrl+k
: Delete current selected resourceCtrl+l
: Show logs for the selected resourceCtrl+f
: Show Port Forwarding dialog for the selected podCtrl+g
: Show active Port Forwards
RUST_BACKTRACE=1 cargo run -- --module-dirs ./default_config/modules --extractor-dirs ./default_config/views/list --detail-template-dirs ./default_config/views/detail
- Describe the Resource List view YAML. Top-level sections are:
resource
: there you describe Group, Version, Kindimports
: automatically prepend for each column evaluator script these linespseudo_resources
: an extractor for nested resource list (return a list ofPseudoResource
items; forPod
pseudo-resource is a container)events
: show either a pseudo resource table or an HTML detail templatecolumns
: a list of column evaluators with column namesdetails
: for HTML-based views specify a root template and rhai helpers
- If you need an HTML detail view, describe templates. Includes and template inheritance is supported.
- When writing column evaluators, use
Ctrl+P
hotkey to extract currently selected resource as a rhai object.
- Resource multiselect (i.e., to delete multiple resources at once)
- Resource kill options support
- Faster Log view
- Better shell selector (now it uses
sh
always) - Port Forwarding
- Configurable hotkeys
- rhai-based context extractors for rendering with support for multiple resources (when you need to solve N+1 problem for resource detail view and show some dependencies)
- Log mirroring to a file
- Prepare more detail and list views for more GVKs
- Support for popular CRDs (helm, GitOps, etc)
- Solve a problem with panics handler breaking the terminal