Managing Plugins

The help option explains basic operation. After installation ensure the $PATH includes the plugins. krew should allow easy installation and use after that.

$ export PATH="${KREW_ROOT:-$HOME/.krew}/bin:$PATH"

$ kubectl krew search

NAME              DESCRIPTION                                           INSTALLED
access-matrix     Show an RBAC access matrix for server resources       no
advise-psp        Suggests PodSecurityPolicies for cluster.             no
....

$ kubectl krew install tail

Updated the local copy of plugin index.
Installing plugin: tail
Installed plugin: tail
\
 | Use this plugin:

....

 | | Usage:
 | |
 | | # match all pods
 | | $ kubectl tail
 | |
 | | # match pods in the 'frontend' namespace
 | | $ kubectl tail --ns staging
....

In order to view the current plugins use:

kubectl plugin list

To find new plugins use:

kubectl krew search

To install use:

kubectl krew install new-plugin

Once installed use as kubectl sub-command. You can also upgrade and uninstall.

Last updated