Skip to content

kx labels

Shows every label on one or more indexed resources, one table per resource. --selector reformats the same data as a copy-pastable label selector.

Usage

kx labels [OPTIONS] <index>...

Arguments

ArgumentDescription
<index>...Row number from the current listing, @name for a mark, or kind/name such as deploy/api

Options

OptionDescription
--context stringKubeconfig context of a kind/name target; defaults to the current one. An index carries its own
-n, --namespace stringNamespace of a kind/name target; defaults to the current namespace. An index carries its own
-s, --selectorOutput as a copy-pastable label selector

Global options

OptionDescription
--no-colorDisable styled output
-h, --helpShow this message and exit

Examples

kx labels 1
kx labels 1 2 3
kx labels 1..3
kx labels 3..
kx labels deploy/api -n prod