Any suggestion where I can get and install kubectl man pages? Asking Google all the time is getting annoying.
I want to be able to see the man page from the command line like:
$ man kubectl pods
I obviously know about the documentation online on the internet.
Thanks
The
kubectl
CLI is written in Golang, and use Cobra features to automatic generate documentation based on subcommands, flags, etc.So, you can use
kubectl --help
to see all the available options. Furthermore, you can dig into specific subcommands options (e.g.,kubectl describe --help
,kubectl get --help
and so on).More than that, you can use
kubectl explain
to describe the fields associated with each supported API resources, which is very useful when writing templates. Examples:I don't think there is a man page for this. But the CLI reference is here and can be bookmarked:
https://kubernetes.io/docs/reference/kubectl/kubectl/