Back to questionsWhich Pods does this selector in the Deployment
JuniorTheoryVery common
Which Pods does this selector in the Deployment web match?
selector:
matchLabels:
app: web
tier: frontendEvery Pod in the namespace whose labels include both app: web and tier: frontend, whatever other labels it carries
- Reading the pairs of
matchLabelsas OR rather than AND - Expecting extra labels on a Pod to keep it out of the match
- How do you list the same Pods with
kubectl get pods -l? - What can
matchExpressionsexpress thatmatchLabelscannot?