What are labels, selectors and annotations?
BeginnerConceptPods & Workloads
Answer
Labels are key/value pairs used to identify and group objects; selectors query them (app=web,tier=frontend) and Services, ReplicaSets and NetworkPolicies depend on them. Annotations hold non-identifying metadata (build info, tool config) and are not used for selection.
kubectl get pods -l app=web,tier=frontend --show-labels