Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
K

kubie

> 云原生
Open source

A more powerful alternative to kubectx and kubens

2.6K stars0 likes2 views
WebsiteGitHub

About

A more powerful alternative to kubectx and kubens

Kubie

[!IMPORTANT] Please see issue #385 regarding the future of Kubie development.

kubie is an alternative to kubectx, kubens and the k on prompt modification script. It offers context switching, namespace switching and prompt modification in a way that makes each shell independent from others. It also has support for split configuration files, meaning it can load Kubernetes contexts from multiple files. You can configure the paths where kubie will look for contexts, see the settings section.

Kubie also has other nice features such as kubie exec which allows you to execute commands in a context and a namespace without having to spawn a shell and kubie lint which scans your k8s config files for issues and informs you of what they are.

  • Installation
  • Usage
  • Settings
  • Future plans

Thanks to @ahermant for the lovely logo!

Installation

Binary

You can download a binary for Linux or OS X on the GitHub releases page. You can use curl or wget to download it. Don't forget to chmod +x the file!

Cargo

You can build kubie from source using cargo and crates.io. If you do not have a Rust compiler installed, go to rustup.rs to get one. Then you can run cargo install kubie and kubie will be downloaded from crates.io and then built.

Homebrew

You can install kubie from Homebrew by running brew install kubie.

MacPorts

You can also install kubie from MacPorts by running sudo port install kubie.

Nix

There is a kubie Nix package maintained by @illiusdope that you can install.

Arch Linux

kubie is available in the extra repository, and it can be installed by running pacman -S kubie.

Autocompletion

Autocompletion can be enabled by adding one of the following lines to your shell's configuration file, e.g., ~/.bashrc or ~/.zshrc:

bash
# Bash / Zsh / others
source <(kubie generate-completion)
# Fish
kubie generate-completion fish | source

See the clap-complete docs for all supported shells.

Usage

Selectable menus will be available when using kubie ctx and kubie ns.


  • kubie ctx display a selectable menu of contexts
  • kubie ctx <context> switch the current shell to the given context (spawns a shell if not a kubie shell)
  • kubie ctx - switch back to the previous context (session history inside a kubie shell, last globally-used context otherwise)
  • kubie ctx <context> -r spawn a recursive shell in the given context
  • kubie ctx <context> -n <namespace> spawn a shell in the given context and namespace
  • kubie ns display a selectable menu of namespaces
  • kubie ns <namespace> switch the current shell to the given namespace
  • kubie ns - switch back to the previous namespace
  • kubie ns <namespace> -r spawn a recursive shell in the given namespace
  • kubie exec <context> <namespace> <cmd> <args>... execute a command in the given context and namespace
  • kubie exec <wildcard> <namespace> <cmd> <args>... execute a command in all the contexts matched by the wildcard and in the given namespace
  • kubie exec <wildcard> <namespace> -e <cmd> <args>... execute a command in all the contexts matched by the wildcard and in the given namespace but fail early if any of the commands executed return a non-zero exit code
  • kubie export <context> <namespace> prints the path to an isolated config file for a context and namespace
  • kubie edit display a selectable menu of contexts to edit
  • kubie edit <context> edit the file that contains this context
  • kubie edit-config edit kubie's own config file
  • kubie lint lint k8s config files for issues
  • kubie info ctx print name of current context
  • kubie info ns print name of current namespace
  • kubie info depth print depth of recursive contexts
  • kubie update will check the latest kubie version and update your local installation if needed

Settings

You can customize kubie's behavior with the ~/.kube/kubie.yaml file. The settings available and their defaults are available below.

…

For distro maintainers

Since 0.19.0, the self update functionality is behind a feature. You can use cargo build --release --no-default-features to produce a binary without the self update functionality. It's probably better if people rely on the distro's package manager for updates over this functionality. The binary produced is also quite smaller since it has fewer dependencies.

Future plans

  • Integration with vault to automatically download k8s configs from a vault server
  • Import/edit configs

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

Rustkubectlkubectxkubenskubernetes

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 17, 2026
Category云原生
PricingOpen source

> Related tools

K
Kubernetes
容器编排事实标准
H
Helm
Kubernetes 包管理器
S
seaweedfs
SeaweedFS is a distributed storage system for object storage (S3), file systems, and Iceberg tables,