Entering the command mode and typing a resource name or alias could be cumbersome for navigating thru often visited resources. By leveraging hotkeys, K9s can be configured to quickly navigate to your favorite resources. In order to enable hotkeys please follow these steps:

  1. Create a file named $XDG_CONFIG_HOME/k9s/hotkey.yml
  2. Add the following to your hotkey.yml. You can use resource name/short name to specify a command ie same as typing it while in command mode.

Not feeling so hot? Your custom hotkeys will be listed in the help view ?. Also your hotkey file will be automatically reloaded so you can readily use your hotkeys as you define them.

You can choose any keyboard shortcuts that make sense to you, provided they are not part of the standard K9s shortcuts list.

This configuration might change in future releases!


# $XDG_CONFIG_HOME/k9s/hotkey.yml

  # Hitting Shift-0 navigates to your pod view
    shortCut:    Shift-0
    description: Viewing pods
    command:     pods

  # Hitting Shift-1 navigates to your deployments
    shortCut:    Shift-1
    description: View deployments
    command:     dp

  # Hitting Shift-2 navigates to your xray deployments
    shortCut:    Shift-2
    description: XRay Deployments
    command:     xray deploy


© 2020 Imhotep Software LLC. All materials licensed under Apache v2.0