A plugin that displays the current Kubernetes context in the DMS bar with the ability to switch between contexts.
- Display current kubectl context in the DankBar
- Quick context switching via popup menu
- Configurable refresh interval (default: 300 seconds)
- Custom kubeconfig path support (default: ~/.kube/config)
- Auto-close popup after context selection
- Visual indicators for active context
mkdir -p ~/.config/DankMaterialShell/plugins/
git clone https://github.com/psyreactor/dms-kubernetes.git kubernetes- Open DMS Settings Super + ,
- Go to the "Plugins" tab
- Enable the "Kubernetes" plugin
- Configure settings if needed (kubeconfig path, refresh interval)
- Add the "kubernetes" widget to your DankBar configuration
- Kubeconfig Path: Path to your Kubernetes config file (default:
~/.kube/config) - Refresh Interval: How often to refresh the current context in seconds (default: 300, range: 30-600)
The widget shows:
- Bar: Anchor icon ⚓ + current context name
- Popup: List of all available contexts with the ability to switch by clicking
plugin.json- Plugin manifest and metadataKubernetesWidget.qml- Main widget componentKubernetesSettings.qml- Settings interfaceREADME.md- This file
This plugin requires:
settings_read- To read plugin configurationssettings_write- To save plugin configurations
kubectlcommand-line tool must be installed and accessible in PATH- Valid kubeconfig file at the configured path
The plugin uses kubectl commands to:
- Get the current context:
kubectl config current-context - List all contexts:
kubectl config get-contexts -o name - Switch contexts:
kubectl config use-context <context-name>
All commands respect the configured kubeconfig path.
